-
Notifications
You must be signed in to change notification settings - Fork 17
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
Supporting frameworks other than Exposed like ktorm #136
Comments
@ashokgelal |
@ashokgelal |
Sure. A part of this use case is that since I'm using Ktorm and not Exposed, I'd like to be able to run migrations like so: override fun up() {
create(Departments)
} Where I ran into a few of issues trying to use Harmonica programatically via an API:
I hope that makes sense. I really believe that this library is great but I'm not a big fan the gradle plugin commands. I wish there was a core of harmonica I could use programatically. I was thinking of doing a hard fork and stripping out all the plugin cruft (and some other parts) but then I was too afraid to make that jump :) Anyway, maybe you could find some time to make another library based on the spirit of Harmonica that is tightly integrated with Ktorm and I then I could make it a core dependency of a framework I'm working on :) I'm more than willing to offer my help and feedback. Thank you for this awesome library! |
I ended up doing a hard fork and tailored it according to my requirements. Thanks to harmonica, I didn't have to do crazy refactoring. And thanks to you. |
@ashokgelal This is just an idea.
class KtormMigration : AbstractMigration
fun create(ktorm: KtormObject) {
// convert ktorm to SQL
val sql = ...
execute(sql)
}
end class M123_Migration : KtormMigration
fun up() { ... }
fun down() { ... }
end I'm not familiar with Ktorm, so I have to study it. Gradle command issue is another one. I'm wondering which is better. As you can see, this library hides most of the innter classes with Thank you for your collaboration. |
@KenjiOhtsuka I appreciate you trying to continue to work on it. But like I said, I have hard forked this and customize it according to my needs. If you want to check out how I've customized it, you can check it out here: https://github.com/alpas/alpas/tree/master/core/src/main/kotlin/dev/alpas/lodestar/migration I don't want you to spend a bunch of time on modifying harmonica to fit my needs, as I'm probably not going to use it. However, if you are interested and have some time, even if it is in future, I'd love to have you collaborate with me on improving https://github.com/alpas/alpas/tree/master/core/src/main/kotlin/dev/alpas/lodestar/migration (I could use some help with tests and supporting Ktorm). I'd be more than happy to mention harmonica in the documentation. I'll let you decide, of course. :) |
Is your feature request related to a problem? Please describe.
It'd be nice to be able to use harmonica with frameworks other than Exposed without having to download extra dependencies.
Describe the solution you'd like
Write an abstraction adapter just like the way JDBC does for different databases.
The text was updated successfully, but these errors were encountered: