About find

forum_thread

@OneToMany(fetch = FetchType.LAZY) list is always null

Hello. @OneToMany(fetch = FetchType.LAZY) doesn't work when using EJB or something else related to J2EE. parent.getChildren() returns null. Here is a simple example: Bean: ...   id = parent. getId ; parent = find ( id ) ; parent. getByteData ( ) . ... the getter of data of byteData   parent = find ( id ) ; merge ( parent ) ; // ...

 
release

2.5.5

... Added support of using entity instead of a PK in find (retrieval by example). Added support of using list of ... . Fixed a bug in optimistic locking on find by using LockModeType.WRITE . Fixed exception when a ...

 
issue

New entity objects are duplicated on merge cascading

When merge is cascaded to a new entity object that has not been persisted yet - it becomes persisted twice. This was demonstrated by a Java EE application in this forum thread but may be reproduced also in a simple console test case: ... ( ) ; Book book = em. find ( Book. class , 1 ) ; em. close ( ... ( ) ;   A a = em. find ( A. class , 1L ) ; B b = new B ( ...

 
forum_thread

openejb jpa jaas module

    hello , i've finished jpa jaas module. Here it is :   package com.bayner.auth; import com.bayner.jpa.Principals; import com.bayner.jpa.UserInfo; import com.bayner.jpa.UserPrincipal; ... {   info = entityManager. find ( UserInfo. class , username ) ; ... final Principals principals1 = entityManager. find ( Principals. class , principalId ) ; ...

 
issue

again merger missing logs + objectdb exception

we are facing similar problems as we had before, in the log we have a lot of entries merger ... missing + an objectdb exception. Some objects in the system behave strange. This is a part of the log: ... [2017-09-26 12:16:14 #1222 store] SectionClassifier: SectionClassifier{238146996->merger[3309]-missing:1} [2017-09-26 12:16:25 #1223 store] SectionClassifier: SectionClassifier{238146996->merger[3309]-missing:1} ... Please consider enabling recording . If we cannot find the cause now by analyzing the database this could enable reproducing the ... 07:55 We will try to find that query edit ...

 
issue

Remove of an entry from a @OneToMany collection is not possible if the enhancer is disabled

Hello! When the JPA entities are not enhanced the remove of an entry from a @OneToMany collection is not possible. The following java code demonstrates the problem. The statement parentEntity.getChildEntityContainer().remove("01"); does not work with not enhanced JPA entities. ... ) ;   parentEntity = entityManager. find ( ParentEntity. class , 1l ) ; Assert. assertEquals ... clear ( ) ;   e = em. find ( MyEntity. class , 1l ) ; Assert. ...

 
forum_thread

Getting java.lang.ArithmeticException: / by zero

HI, I am using ObjectDb 1.x and getting the following exception while calling the following code PersistenceManager pm = getPersistenceManager(); ... 14:09 Please find the attached object db jar. odbee.jar ... 20:18 I couldn't find the build number. It may be a very old jar. Please try the ...

 
release

2.4.0

... . Fixed a bug in optimistic locking on find by using LockModeType.WRITE . Fixed exception when a ... id type when an entity object is retrieved using  find  with a PK of a different type (e.g. Integer instead of Long ...

 
forum_thread

Database(*.odb) file size on disk

Hello, we have questions about the file size of ObjectDB database on disk. Can you tell us something about how the deleting of entities affects the size of *.odb files on disk? -Will the released memory always used by new entities? -Will be the database file automatically reduced?   We have created a small test, in which we create and delete entities. It looks like that the released memory are reused but the the file not resized. The database is at the end empty again, but larger than the initial size. ... + entityB. id ; EntityA entity = em. find ( EntityA. class , entityAIds. get ( i ) ) ... ( ) ; EntityA entity = em. find ( EntityA. class , entityAIds. get ( i ) ) ...

 
forum_thread

in-memory and on-disk support?

I've had a quick read through the features/FAQ and haven't been able to find a clear answer. I'm looking at replacing a setup of H2 where I have 40GB in-memory backed by 800GB on-disk, the 40GB in memory represents the first 40GB of the 800GB on-disk for super-fast recent entry searching, the records at the end continuously purge as the new ones come in(duplicate write, one to in-memory and one to on-disk). ... read through the features/FAQ and haven't been able to find a clear answer. I'm looking at replacing a setup of H2 where I ... usually uses free physical memory as cache, so you may find that you get the performance that you need also with one database. ...