1

I'm using a Spring Data Source bean to configure a JDBC connection.

What's the easiest way to have this return a bare, unpooled / unmanaged JDBC connection?

Alex R
  • 11,137
  • 13
  • 86
  • 164

1 Answers1

2

I think you are looking for org.springframework.jdbc.datasource.SimpleDriverDataSource this class is a very simple implementation of javax.sql.DataSource and doesn't implement connection pooling, instead it always returns a new connection.

You can find source code here

Alex R
  • 11,137
  • 13
  • 86
  • 164
malaguna
  • 4,128
  • 1
  • 16
  • 33