About Transaction

forum_thread

ODB lost?

I'm new to ObjectDB. While debugging small programs in single-step mode in NetBeans, the ODB appears to get corrupted or lost if I don't invoke close on EntityManager. If I re-run my program and get a new EntityManager, the instance behaves as if the data that was persisting is somehow gone. I noticed in the file system, indeed, the .odb file is gone, but there are <name>_<v>.odb files where <name> is the name of my odb and <v> is apparently a version number. Is there any way to recover <name>.odb? #1 2011-03-18 23:11 I'm new to ObjectDB. While debugging small programs in single-step mode in NetBeans, the ODB appears to get corru ...

 
forum_thread

Problem with bidirectional link

(I had raised this issue in the past and have finally had time to come back to it and strip down the classes to a minimum). The problem seems to lie in having bidirectional links (viz, I have @OneToMany Map<String, Entry> children and @ManyToOne Entry parent in my classes. I've attached the offending classes. If I add an entry to the children I get an error. I'm wondering if it's a question of multiple references to the same instance of a class? It's hard to tell with the opaque code of ObjectDB. ... javax.persistence.RollbackException Failed to commit transaction: Attempt to persist a reference to a non managed Folder instance - ...

 
issue

Unexpected Exception during commit

I'm testing code that otherwise has been working with a clean database. I have seen several examples of the following exception. It never seems to happen in the same place twice, though. If you can give me a hint as to what would internally cause this, I'll try to reproduce it. Carl   ... javax.persistence.RollbackException Failed to commit transaction: Unexpected internal exception (error 613) at ...

 
api-jpa

javax.persistence.NamedQuery

Specifies a static, named query in the Java Persistence query language.(Annotation of JPA)

 
api-jdo

Constants.TX_READ_UNCOMMITTED

Transaction isolation level representing the ability to read uncommitted data.(Static Field of javax.jdo.Constants)

 
issue

preUpdate-methods are called when there is no change

Dear Support Team, we ran into some difficulties with a database. When fetching a entity using the EntityManager and afterwards calling "iterator().next()" a transaction begin/commit will end up in updating the Entity even there was no change. We attached a simplified test case where only 2 reduced versions of the entities are available. But it still shows the unexpected behavior. To reproduce just run the "EntryPoint" class. ... EntityManager and afterwards calling "iterator().next()" a transaction begin/commit will end up in updating the Entity even there was no ...

 
api-jpa

javax.persistence.PersistenceException

Thrown by the persistence provider when a problem occurs.(Exception of JPA)

 
api-jdo

getTransactionalObjectId(pc)

Return a copy of the JDO identity associated with the parameter instance.(Method of javax.jdo.spi.StateInterrogation)

 
forum_thread

how to persist an object twice into two diff. collections of two diff. classes

ok my problem,    i persist a Squad Object into a Cup Object at the beginning, after i have to create and persist a competition object in which i have to put some of the already created/persisted squads. the final method looks like that: ... persistence . RollbackException Failed to commit transaction : Attempt to reuse an existing primary key value ( ...

 
api-jdo

setConnectionFactory2(connectionFactory)

Set the second data store connection factory.(Method of javax.jdo.PersistenceManagerFactory)