Open
Description
In the application some JPA relations are one-to-many and by default lazy loaded. When fetching the aggregate-root through the repository the returned root object will be detatched. Eclipselink handles this for read operations but Hibernate would throw a LazyInitializationException.
A traditional solution would be to add methods to a DAO such as loadCargoWithLoadedLegs();
With a lot of lazy collections and many combinations this would quickly be a bloated interface.
As a developer I would like to fetch the root, access and make changes to any object in graph, then store the root and have all changes persisted.