Hibernate Traps: A Leaky Abstraction
Introduction Welcome to my new series of articles that will take on a various traps and pitfalls we can encounter when using Hibernate. This is not another rant about why Hibernate is bad and why you shouldn't use it. Like it or not, Hibernate is one of the most widely used technologies in the Java world and sooner or later every Java developer will have to use it in some way. Nevertheless it is a huge and complicated Framework that, in order to be as generic as possible, has a lot of behaviors ranging from not so obvious to downright weird and quirky. It's better to be prepared and to know what we're dealing with, and how it works underneath. That's why my first article in the series is entitled... A Leaky Abstraction Hibernate's main selling point for majority of Java developers is that it takes care of the SQL side of things so we don't have to get our hands dirty with writing SQL Statements, we can just use pretty Java objects instead. The funny thing is t...