Community
Participate
Working Groups
When an Order Column is specified for a collection mapping, under certain circumstances a NullPointerException can occur when the mapping's valueFromPKList(Object[], AbstractSession) method is invoked. This issue is occurring because the code in ContainerPolicy that initializes the list order field replaces an already initialized ContainerPolicy with a new OrderedListContainerPolicy. This new policy is not initialized, and thus the policy's elementDescriptor field is null, leading to a later NPE when valueFromPKList is called.
Created attachment 201191 [details] Proposed patch and testcase
Created attachment 201284 [details] Updated patch Correcting testcase and moving @OrderColumn, due to issues in testing
Created attachment 201411 [details] Updated patch Patch now utilizes its own model classes.
Fixed in EclipseLink trunk (2.4) r9882
Checked into 2.3 branch (2.3.1) at r9885
Checked into 2.2 trunk at r9887
Checked into 2.1 trunk at r9891
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink