This discussion is archived
13 Replies Latest reply: Jun 8, 2012 11:07 AM by newToplinkUser RSS

OptimisticLockException.getObject returns null

newToplinkUser Newbie
Currently Being Moderated
a NPE is thrown when we try to access the object, Eclipselink 2.3.3, is this a known issue? Thanks

java.lang.NullPointerException: null
at
org.eclipse.persistence.exceptions.OptimisticLockException.getObject(OptimisticLockException.java:65)
at
com.integral.persistence.PersistenceFactory.handleException(PersistenceFactory.java:1010)
at
org.eclipse.persistence.internal.sessions.AbstractSession.handleException(AbstractSession.java:2739)
at
org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1561)
at
org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1498)
at
org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1449)
at
org.eclipse.persistence.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:224)
at
org.eclipse.persistence.internal.sessions.CommitManager.commitAllObjectsForClassWithChangeSet(CommitManager.java:191)
at
org.eclipse.persistence.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:136)
at
org.eclipse.persistence.internal.sessions.AbstractSession.writeAllObjectsWithChangeSet(AbstractSession.java:3799)
at
org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitToDatabase(UnitOfWorkImpl.java:1415)
at
org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitToDatabaseWithChangeSet(UnitOfWorkImpl.java:1505)
at
org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitRootUnitOfWork(UnitOfWorkImpl.java:1325)

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points