Any idea when/if nonblocking i/o for db access will make percolate its way through enough of a standardization process that jooq will expose it? I'd love to be able to use jooq without having a threadpool around to do blocking i/o on.

There's at least some activity on the mailing list ostensibly associated with getting ADBA done: http://mail.openjdk.java.net/pipermail/jdbc-spec-discuss/. Both pgadba and pgnio both seem to be in a holding pattern waiting for ADBA to firm up, though, and I think ADBA was last mentioned on the jooq blog on a 4/1 post. ;)

What I need to do now (in Kotlin + coroutines):

// toss the work into a thread pool for blocking i/o
val result = withContext(Dispatchers.IO) {
    jooq.transactionResult { txn ->
        // run queries here
    }
}

API wise, it'd be sometimes convenient to have the callback provided to `transactionResult` be a suspending function for nicer integration with coroutines, but rearranging things to be based around CompletableFutures would be just about everything I want, and I could probably build a suspending helper function on top of that.

--
You received this message because you are subscribed to the Google Groups "jOOQ User 
Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jooq-user/e7a4c55d-1ec8-5bfe-4745-dc36432b019f%40mpierce.org.
For more options, visit https://groups.google.com/d/optout.

Reply via email to