-
Notifications
You must be signed in to change notification settings - Fork 346
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
multi-target sources #379
Comments
Workaround |
I made an example project showing how to switch between MySQL and H2 JDBC contexts at compile-time. Do not forget to checkout |
If someone needs to switch between sync (e. g. |
@getquill/maintainers I've been thinking about this feature but I couldn't find a good way to implement it. I think I'll remove it from the |
@fwbrasil 👌 We receive questions about context switching on Gitter channel occasionally. But people usually ask about compile-time context switching which can be done by above workaround though it does not work in all cases (for example, when switching sync and async contexts). I think that fixing bugs is top priority now and this feature can wait. |
any progress or plans to resolve this issue? |
@getquill/maintainers I suggest to close this in favor of #971, since introducing multi-target sources should be avoided in favor of generating queries using idioms and io monad. Wdyt? |
Version: (e.g.
0.6.0
)Module: (e.g.
quill-core
)Problem
Quill doesn't provide an easy way to switch to a different SQL dialect at runtime. Queries are generated at compile time and the application needs to be recompiled in order to run on another target dialect.
Solution
Introduce multi-target sources, that generate queries against multiple compatible target sources at compile-time and allows the user to choose the target source type at runtime.
By "compatible" target sources I mean sources that have the exact same method signatures. For instance, it'd be possible to have a
but not
The macro would generate a message for all targets:
@getquill/maintainers
The text was updated successfully, but these errors were encountered: