Type safety is a desirable characteristic of both Java and Scala, but querying database objects in a type safe way in Java has always been clumsy. Scala helps us create type safe DSLs and this talk will go through how to use the Hibernate DSL api to create queries and criterias.
Navigating between relationships is also improved both in Java and in Scala as functional programming style features are added to the APIs: now Hibernate's and JPAs lazy support becomes even stronger than its extra-lazy feature.
The session will show how to use the DSL in several examples and do a simple overview to show how the code is implemented behind the scenes.