bwajtr / java-persistence-frameworks-comparison

Comparison of non-JPA SQL mapping frameworks for Java (Jooq, Spring JDBCTemplate, MyBatis, EBean, JDBI, Speedment, sql2o)
MIT License
264 stars 35 forks source link

Fixed jOOQ "findCompanyUsingSimpleStaticStatement()" #11

Closed lukaseder closed 7 years ago

lukaseder commented 7 years ago

Hey, thanks for doing this comparison. Here's some idea about how to improve on one of the FIXMEs.

An alternative, if you do want to keep the DSLContext.connection(c -> { ... }) idiom in place would be to use DSLContext.connectionResult(c -> DSL.using(...).selectFrom(...).where(...).fetch(...)) instead, then you could get rid of that AtomicReference workaround.

Hope this helps, Lukas

bwajtr commented 7 years ago

Awesome, this looks much better. Thanks Lukas.