Next stop on the Annotatiomania™ Train: FetchGroups

Here's how an Annotatiomaniac™ can optimise his second-level cached JPA queries conveniently by adding yet more annotations (what else?) to his simple and plain POJO's. Remember that EJB 3.0 was about removing dependencies from javax.ejb.EJBObject, javax.ejb.EJBHome and similar interfaces? Well... check out this example: import org.apache.openjpa.persistence.*; @Entity @FetchGroups({ @FetchGroup(name="detail", attributes={ @FetchAttribute(name="publisher"), @FetchAttribute(name="articles") }), ... }) … Continue reading Next stop on the Annotatiomania™ Train: FetchGroups