Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] @OptimisticLocking => NullPointerException

Dear EclipseLink community,

We are getting a NullPointerExcption when using @OptimisticLocking.

org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy
is the class where it happens:

CascadeLockingPolicy.initUnmappedFieldsQuery(...) {
...
SQLSelectStatement statement = new SQLSelectStatement();
Iterator<DatabaseField> itUnmappedFields = m_unmappedQueryKeyFields.values().iterator();
...
}

called by

CascadeLockingPolicy.initUnmappedFields(...) {
...
 if(m_unmappedQueryKeyFields.isEmpty()) {
                 m_unmappedQueryKeyFields = null;
                 m_mappedQueryKeyFields = m_queryKeyFields;
             }
  initUnmappedFieldsQuery(uow);
...
}

Just 2 statements before initUnmappedFieldsQuery() is using m_unmappedQueryKeyFields, it is set to null.

Is ths a bug or does anybody know which circumstances, e.g. annotations in our entities, could lead to this problem?`

Best regards
... Michael

--
http://michael.hoennig.de


Back to the top