Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a DriverProvider SPI abstracting over JDBC to allow for using non-blocking, async drivers with jOOQ #6298

Open
lukaseder opened this issue May 30, 2017 · 4 comments

Comments

Projects
None yet
3 participants
@lukaseder
Copy link
Member

commented May 30, 2017

Currently, jOOQ is strictly tied to JDBC throughout its internals and existing SPIs, like ExecuteListener, ConnectionProvider, and others.

But that's not a hard requirement. We could implement a new DriverProvider SPI, which allows for implementing all the driver binding glue code that is required by jOOQ, e.g.:

  • A wrapper of a connection / session
  • A wrapper for transactions
  • A wrapper for prepared statements
  • A wrapper for bind variable bindings
  • A wrapper for result sets
  • A wrapper for procedures and in / out parameters
  • More...

Once this SPI is in place, we can support third party non-blocking drivers other than JDBC drivers e.g. for PostgreSQL and SQL Server, which can then make truly non-blocking calls through methods like ResultQuery.fetchAsync()

A lot of research needs to go into this issue.

An example implementation using https://github.com/alaisi/postgres-async-driver could be provided.

@lukaseder lukaseder added this to the Version 3.11.0 milestone May 30, 2017

@lukaseder lukaseder changed the title Implement a DriverProvider SPI abstracting over JDBC to allow for using non-blocking drivers with jOOQ Implement a DriverProvider SPI abstracting over JDBC to allow for using non-blocking, async drivers with jOOQ Jun 6, 2017

@mkurz

This comment has been minimized.

Copy link

commented Feb 27, 2019

This would be really great! I guess this is related to #7605?

Another pointer here would be jasync-sql/jasync-sql (which is a port of the deprecated, Scala based mauricio/postgresql-async to Kotlin).

@lukaseder

This comment has been minimized.

Copy link
Member Author

commented Feb 28, 2019

@mkurz Thanks for the pointer. Yes that other issue is a duplicate of this one.

I'm really going to focus on supporting ADBA and/or R2DBC, as these will quite likely involve into standard APIs, unlike these many PostgreSQL-specific proprietary APIs

@davinkevin

This comment has been minimized.

Copy link

commented May 13, 2019

I think this issue will be my favorite of all Github ! I dream of being able to use JOOQ in a reactor env without relying on JDBC and Thread Pool.

@lukaseder

This comment has been minimized.

Copy link
Member Author

commented May 14, 2019

@davinkevin Of course, you can already do that today, writing just a few lines of glue code and calling Query.getSQL() and Query.getBindValues()...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.