Comments on: Hibernate: dealing with lazy loading inevitable https://technology.amis.nl/2004/11/17/hibernate-dealing-with-lazy-loading-inevitable/ Friends of Oracle and Java Wed, 15 Apr 2015 12:11:59 +0000 hourly 1 http://wordpress.org/?v=4.1.1 By: More on boilerplate and IoC at Al Maw https://technology.amis.nl/2004/11/17/hibernate-dealing-with-lazy-loading-inevitable/#comment-1120 Wed, 06 Dec 2006 13:14:58 +0000 /?p=260#comment-1120 […] Myth #4: “You can replace Hibernate with something else, and your API consumer doesn’t have to change anything, because it’s all just interfaces!” Err, yes. What’s to stop you writing against your interfaces and making a factory class for your DAOs which hides the Hibernate bits as much as possible? Why would you need IoC for that? Besides, has anyone ever actually done this? If you can find a complex app where replacing the Hibernate layer with some other technology would involve no DAO interface changes, I’ll eat my hat. Hibernate and your DAO interfaces are an abstraction. Abstractions leak. Lazy-loading, in particular, leaks like a sieve, all the way across your nice tiered app. Ah, implement an OpenSessionInView filter, I hear you say. Which promptly leaks in three-tier designs where your domain objects are pulled across RMI or whatever. […]

]]>
By: Java boilerplate and an IoC rant at Al Maw https://technology.amis.nl/2004/11/17/hibernate-dealing-with-lazy-loading-inevitable/#comment-1119 Wed, 06 Dec 2006 12:13:35 +0000 /?p=260#comment-1119 […] Myth #3: “You can replace Hibernate with something else, and your API consumer doesn’t have to change anything, because it’s all just interfaces!” Err, yes. Has anyone ever actually done this? If you can find a complex app where replacing the Hibernate layer with some other technology would involve no DAO interface changes, I’ll eat my hat. Hibernate and your DAO interfaces are an abstraction. Abstractions leak. Lazy-loading, in particular, leaks like a sieve, all the way across our nice MVC or whatever tiered app. […]

]]>
By: » Hibernate and Middlegen revisited https://technology.amis.nl/2004/11/17/hibernate-dealing-with-lazy-loading-inevitable/#comment-1118 Wed, 30 Nov -0001 00:00:00 +0000 /?p=260#comment-1118 […] Report In my last two posts (Hibernate + Middlegen Roundtrip Development applied and Hibernate: dealing with lazy loading inevitable), I explained how to construct a J […]

]]>