[OS-JIRA] Created: (CAY-74) SnapshotManager.isToOneTargetModified(..) breaks when the target is NEW

From: jir..bjectstyle.org
Date: Fri Jan 09 2004 - 17:02:45 EST

  • Next message: Andrus Adamchik: "Re:..uthor tags in community projects"

    Message:

      A new issue has been created in JIRA.

    ---------------------------------------------------------------------
    View the issue:

      http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-74

    Here is an overview of the issue:
    ---------------------------------------------------------------------
            Key: CAY-74
        Summary: SnapshotManager.isToOneTargetModified(..) breaks when the target is NEW
           Type: Bug

         Status: Assigned
       Priority: Major

        Project: Cayenne
     Components:
                 Cayenne Core Library
       Fix Fors:
                 1.0 [STABLE]
       Versions:
                 1.0 [STABLE]
                 1.1 [DEV]

       Assignee: Andrus Adamchik
       Reporter: Andrus Adamchik

        Created: Fri, 9 Jan 2004 5:02 PM
        Updated: Fri, 9 Jan 2004 5:02 PM

    Description:
    When a target of to-one relationship is NEW, SnapshotManager.isToOneTargetModified(..) throws an NPE:

    java.lang.NullPointerException
    at org.objectstyle.cayenne.ObjectId.getValueForAttribute(ObjectId.java:188)
    at org.objectstyle.cayenne.access.SnapshotManager.isToOneTargetModified(SnapshotManager.java:340)

    This usually happens when a source object is being refetched before commit (e.g. if it happens to be a part of to-many relationship being resolved).

    The bug is demonstrated in SnapshotManagerTst.testIsToOneTargetModifiedWithNewTarget() test case.

    ---------------------------------------------------------------------
    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 : Fri Jan 09 2004 - 17:02:46 EST