About eager

forum_thread

Composite indexes

Hi, I read your manual about defining Indexes for JPA Entities (http://www.objectdb.com/java/jpa/entity/index), but I still have some problems understanding how and when should I use them.   Let's start with some example then. Assume we have an entity that represents an interior design image, called Inspiration : ... ( fetch = FetchType . EAGER ) List<Integer> filterDescription ; // some integers ...

 
forum_thread

OEM licencing limitation

Hello, I have question regarding OEM licencing. We have an enhanced entity that contains list of unenhanced entities(by a mistake). We have already received the exception: Too many persistent objects (>1000000) - exceeds evaluation limit on that nonenhanced entity, but we have doubts how is the number of persistent objects counted. We unfortunately don't have the objectdb file anymore, but we have some doubts, that the number was not reached by the internal entitities.... OneToMany ( fetch = FetchType . EAGER , cascade = CascadeType . ALL ) private ...

 
issue

com.objectdb.o.InternalException: null

After an error in a @PrePersist method in an Entity class, the database stopped working. Fortunately this was in development, but still worrying! The Entity class ... = "customer" , fetch = FetchType . EAGER ) private List<Insurance> insurances = new ...

 
forum_thread

LifeCycle Event with Embeddable classes

Hello, is there a way that lifecycle events like prepersist or preupdate are also fired for embeddable classes, not just for entities? My case looks as follows: ... . ALL , fetch = FetchType . EAGER ) private List<Bar> barList ;   @ ...

 
forum_thread

How do I achieve a Deep Fetch using JOIN FETCH?

I have an Entity type which is contains a collection of Embeddable objects, which in turn themselves contain a collection of Embeddable objects: @Embeddable class A { String val; }; @Embeddable class B { List<A> aList; }; @Entity class C { @Id long id; List<B> bList; };   Usually I'm content to have the B's and A's be lazily loaded, but I have a circumstance where I need to be able to work with the whole C object, with all its parts, as a detached object. ... object. I know that I can express one level of eager fetch in JPQL as follows: SELECT c FROM C JOIN FETCH ...

 
forum_thread

Double persist of Entity field with Cascade.ALL

I am building a JavaEE application using Netbeans 7.0.1, Glassfish 3.1 and ObjectDB 2.3.3. I have a Book class with entity field Chapter which has a CascadeType.ALL property. The Book fields are as follows: @Id @GeneratedValue(strategy = GenerationType.AUTO) private Long id; private String bookTitle; @OneToMany(cascade= CascadeType.ALL, fetch= FetchType.EAGER) private List<Chapter> chapters; The Chapter fields are as follows: ... . ALL , fetch = FetchType . EAGER ) private List<Chapter> chapters ; The ...

 
issue

Lazy loading of mapped by (inverse) singular references

Feature Request Version: 2.0.0 Priority: Normal Status: Fixed Replies: 1 Type:  Feature Request ...

 
forum_thread

Weird behaviour with enhanced classes and embedded entities

Hi, I've found some weird behaviour in my project (www.tinymediamanager.org): Sometimes some entries of my ArrayLists with embedded entities are missing. I've hunted the problem down to an enhanced/proxied list in my entity which contains embedded entities and some .add(obj) are simply failing. Here is a small sscce which reproduces the issue: ... . ALL , fetch = FetchType . EAGER ) private List<MyEmbeddedEntity> ...

 
forum_thread

Global way to set Lazy-loading fetch functionality for all the fields

Hi, for cascading persist, I have 3 choices: - Either locally (@OneToOne(cascade=CascadeType.PERSIST)) - Either at objectdb level (<cascade-persist always="auto" on-persist="false" on-commit="true" />) - Either at JPA global level (orm.xml).   For defining fetch policy, I know the local way to do it (@ManyToOne(fetch=FetchType.LAZY)). Is there any way to do it at objectdb level or JPA global level?   ... 20:56 Lazy / Eager can only be set locally per relationship, and for some extent also per ...

 
forum_thread

ObjectDB 2.6.9_06 (embedded): Cascading merge resulting in duplicate objects

This issue maybe related to issue #110 (http://www.objectdb.com/database/issue/110). Because that issue has been closed as "fixed", I am reporting this new issue. This is my class definition: ... OneToMany ( fetch = FetchType . EAGER , cascade = CascadeType . ALL ) private ...