castor
  1. castor
  2. CASTOR-1402

Underlying SQLException information is lost when DuplicateIdentityException is created

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0
    • Fix Version/s: 1.0.1
    • Component/s: JDO
    • Labels:
      None
    • Environment:
      PostgreSQL
    • Number of attachments :
      3

      Description

      when processing SQLException in SQLStatementCreate, code tries to detect duplicate identity exception - if such is detected, new DuplicateIdentityException is created without saving original SQLException (which provides way more information about the cause of the exception) as nested one.

      the patch is really trivial:

      original org.exolab.castor.jdo.engine.SQLStatementCreate code:

      line 326: throw new DuplicateIdentityException(Messages.format("persist.duplicateIdentity", _type, identity));

      corrected code:

      line 326: throw new DuplicateIdentityException(Messages.format("persist.duplicateIdentity", _type, identity), except);

      1. patch.C1402.20060413.txt
        2 kB
        Werner Guttmann
      2. patch.C1402.20060413-002.txt
        10 kB
        Werner Guttmann
      3. patch.C1402.20060413-003.txt
        13 kB
        Werner Guttmann

        Activity

        Werner Guttmann made changes -
        Field Original Value New Value
        Assignee Werner Guttmann [ wguttmn ]
        Werner Guttmann made changes -
        Fix Version/s 1.0.1 [ 12535 ]
        Werner Guttmann made changes -
        Attachment patch.C1402.20060413.txt [ 20107 ]
        Werner Guttmann made changes -
        Attachment patch.C1402.20060413-002.txt [ 20108 ]
        Werner Guttmann made changes -
        Attachment patch.C1402.20060413-003.txt [ 20109 ]
        Werner Guttmann made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ralf Joachim made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Werner Guttmann
            Reporter:
            Yegor Borovikov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: