tier « Load « JPA Q&A





1. cannot perform lazy loading in n-tier web application    forum.hibernate.org

I'm using NH to map DB to an object named `location` which has some properties and on List `` attachments (one-to-many relation with instance of `lcocation`). I use lambda expression to init `location` istance: public IList GetAllByExpression(Expression> expression) { using (ISession session = NHibernateHelper.OpenSession()) { return session.Query().Where(expression).ToList(); } } at some later point in the code I try to access `location.attachments` ...

2. Lazy loading with bussines tier best practices    forum.hibernate.org

Hi all! Hibernate docs on lazy loading. Quote: In an application with a seperate business tier, the business logic must "prepare" all collections that will be needed by the web tier before returning. Usually, the application calls Hibernate.initialize() for each collection that will be needed in the web tier (this call must occur before the session is closed) or retrieves the ...

3. Three Tier Lazy Loading    forum.hibernate.org

Hibernate version: 3.0.5 Name and version of the database you are using: Oracle 9.2.0.4 I'm using Cocoon 2.1.7, Hibernate 3.0.5 and Spring 1.2 to develop a fairly big (5000+ classes) web application. I have a question about best practices when moving domain objects from Hibernate through my Service Layer to my Presentation Layer. This isn't completely Hibernate, but mostly... In anyone's ...

4. Three tier and lazy loading    forum.hibernate.org

Hello, I am using Hibernate and EJB3 (with JBOSS AS) in three tier environment (Eclipse RCP client). I would like to have some advice about dealing with lazy object on the client tier. I am sure expert like you have tricks about it :-) Is DTO is out of date? Are there other solutions to have loosely coupling? Thanks, Regards,