quarkus-jooq icon indicating copy to clipboard operation
quarkus-jooq copied to clipboard

Defaults provided in JooqCustomContext should be documented

Open rkraneis opened this issue 3 years ago • 8 comments

Using quarkus-jooq leads to an out-of-box behavior that is by default different from “plain” jooq. Especially, having set renderCatalog and renderSchema to false was a bit surprising. This should be documented (and ideally easily changeable).

rkraneis avatar Jan 07 '22 09:01 rkraneis

forking here for now until some of these issues are resolved: https://github.com/sort-dev/quarkus-jooq

only missing the pro support I think, the rest is more pure JOOQ without any opinion slipping into the config.

apatrida avatar May 19 '22 18:05 apatrida

Also setQueryTimeout(60) is hard to find config :) Spent half day to find out that it is configured by quarkus-jooq.

deedarb avatar Feb 27 '23 10:02 deedarb

This extension should be removed from quarkiverse recommendation until: (probably too late, but its a mess right now otherwise)

  • the personal preferences of the developer are removed from JOOQ configuration (it should create a raw config as JOOQ would until you customize it)
  • the codegen model is checked, seems clunky versus other similar plugins in what code it generates. At least a code review from someone who actually knows what should be done and not just accepting what happened to be done here.
  • someone is updating it for Quarkus 3.x chain as well as Jooq + Quarkus + Jakarta require some version matching that isn't being maintained here.

apatrida avatar Mar 08 '23 15:03 apatrida

@ranjanashish

apatrida avatar Mar 08 '23 15:03 apatrida

@apatrida Hi, I understand and agree that we need to fix a few things with this extension. A couple of them being

  • configuration, and
  • versioning

However, I did not completely understand your second point

the codegen model is checked, seems clunky versus other similar plugins in what code it generates. At least a code review from someone who actually knows what should be done and not just accepting what happened to be done here.

Can you also provide access to your fork please?

ranjanashish avatar Mar 08 '23 19:03 ranjanashish

Please check this issue aimed at better versioning, and share your thoughts.

ranjanashish avatar Mar 15 '23 22:03 ranjanashish

I have the same problem. I am trying to use a separate schema name and had to track down that renderSchema is set to false. I was looking for a way to override the JooqCustomContext but the fork above is private (or gone?) @apatrida .

bentatham avatar Oct 02 '23 19:10 bentatham

Found a workaround:

  1. Define your own implementation of JooqCustomContext (which a copy of the apply method, with the settings changed as you want).
  2. Set quarkus.jooq.configuration = your.package.YourJooqCustomContext

No need for a full fork.

Ideally, we would be able to paramterize the properties in JooqCustomContext directly in the application.properties for quarkus eg. quarkus.jooq.renderSchema = false. Is there a chance such a PR would be accepted if I added that?

bentatham avatar Oct 02 '23 19:10 bentatham