Message:
A new issue has been created in JIRA.
---------------------------------------------------------------------
View the issue:
http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-310
Here is an overview of the issue:
---------------------------------------------------------------------
Key: CAY-310
Summary: Calling <DataObject>.addTo<DataObject>List() with a null parameter crashes later in commitChanges()
Type: Improvement
Status: Assigned
Priority: Minor
Project: Cayenne
Components:
Cayenne Core Library
Versions:
1.2 [DEV]
Assignee: Andrus Adamchik
Reporter: Mike Kienenberger
Created: Mon, 25 Apr 2005 6:00 PM
Updated: Mon, 25 Apr 2005 6:00 PM
Description:
Calling <DataObject>.addTo<DataObject>List() with a null parameter crashes later with a NullPointer Exception in commitChanges() -> categorizeFlattenedInsertsAndCreateBatches() at
if (info.getDestination().getPersistenceState() == PersistenceState.DELETED) {
continue;
}
This was a difficult error to track down because of the delay between introducing bad data and commiting it.
DataObject.addToManyTarget(String relName, DataObject value, boolean setReverse) should probably throw an exception immediately if "value" is null if this is not an acceptable situation.
If this solution makes sense to you, assign this back to me, and I'll add the fix to cvs (by throwing an NPE immediately).
-Mike
---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
http://objectstyle.org/jira/secure/Administrators.jspa
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
This archive was generated by hypermail 2.0.0 : Mon Apr 25 2005 - 18:01:32 EDT