I am evaluating the Play structure and learning Scala, which was fun. Coming from java, the transition to Scala took a fair bit of psychological gymnastics, but now I'm a fan.
I have a significant database already mapped to using JPA, and I was just about to continue to use this code (with hibernation), however this is not the best or recommended approach with Scala. So I started matching some tables with SLICK, but before I went too far, I realized that I ran into problems with Scala restrictions for classes and functional parameters (no more than 22).
I find it completely incomprehensible that modern ORM will have this limitation. I have no problem with Scala with this limitation - after all, who wants to pass 22 parameters to the function. Therefore, my question is: why create a library with this limit? Surely this should have been designed to match ordinary classes? I don't care if he even used reflection to do the job.
I have seen workarounds for this that require class separation and recombination using implicit conversion. But this is just a hack.
I assume that if I want to continue using Play, then I should switch to Java and use JPA.
source share