https://kotlinlang.org logo
#announcements
Title
# announcements
m

mmaillot

10/15/2017, 7:56 PM
Hi, do you know a good ORM framework for Kotlin ?
k

karelpeeters

10/15/2017, 7:57 PM
There's thin one by JetBrains: https://github.com/JetBrains/Exposed
m

mmaillot

10/15/2017, 8:01 PM
Yes but it's a prototype and when I tried it, it seems required to make all request in a single transaction (like the sample)
c

clubfan

10/15/2017, 8:04 PM
well, you can use all the Java ORMs I think
m

mmaillot

10/15/2017, 8:08 PM
Yes of course, but I'm looking for Kotlin designed ORM (with data class suport, functionnal programming...) I found a few from https://github.com/KotlinBy/awesome-kotlin
I did not find my happiness...
s

Shawn

10/15/2017, 8:17 PM
This doesn’t answer your question directly, but in my project I’m using JDBI for my SQL calls - JDBI is written for Java, but it does have a great plugin that provides data binding support for Kotlin data classes, as well as some extension functions to allow for more functional logic than JDBI provides for in Java
my point being that you may have some luck looking for Java libraries that are also embracing Kotlin and provide plugins or other support for the language
t

trevjones

10/15/2017, 9:55 PM
requery works pretty well with kotlin’
m

mmaillot

10/16/2017, 6:53 AM
Thanks, I test requery and I don't like the code generation. I make my entities and I need to compile my project to genenarte POJO... At this moment, I uses ORMLite. It's support data class and it's pretty easy to use with a good documentation/communauty
l

lewik

10/16/2017, 9:34 AM
Hibernate works with kotlin) data classes and so on)
n

niklas

10/16/2017, 1:30 PM
@mmaillot We used JDBI 2 to great effect, but it had some quirks mainly with Java 8 types like
java.time.*
and
Optional
. We are starting to use JDBI 3 now. It's not yet released but has better Java 8 and Kotlin support and it seems it's mainly missing some documentation at this point. https://jdbi.github.io/#_sqlobject
👌 1
m

mmaillot

10/16/2017, 7:31 PM
@niklas thanks, i'll look this framework.
6 Views