Defining a database connection

You can use jOOQ with any connection pool you prefer. The example for this section uses the same approach we used with plain JDBC, so the connection properties can be defined in a datasource.properties file:

datasource.url=jdbc:h2:tcp://localhost/~/h2-databases/demo
datasource.username=sa
datasource.password=

At this point, you should be familiar with how to use a ServletContextListener to initialize a database connection pool. Let's omit that part (see the section about JDBC for details) and jump directly to more specific topics.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset