OpenJPA
  1. OpenJPA
  2. OPENJPA-2124

Use of XMLValueHandler results in a NullPointerException when classloader does not provide package support

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0, 2.0.1, 2.1.0, 2.3.0
    • Fix Version/s: 2.2.0
    • Component/s: jdbc
    • Labels:
      None
    • Environment:
      JEE Environment
    • Patch Info:
      Patch Available

      Description

      XMLValueHandler is used to convert xml content from database to java object. It threw NullPointerException from XMLValueHandler.toObjectValue() when class loader does not provide package support.

      Basically getPackage() function call in XMLValueHandler.toObjectValue returns null.

      The fix is to parse the entity class name directly to retrieve the package name.

        Activity

        Hide
        Jeremy Bauer added a comment -

        Committed patch for Helen (with minor cleanup) under revision 1242547.

        Show
        Jeremy Bauer added a comment - Committed patch for Helen (with minor cleanup) under revision 1242547.
        Hide
        Helen Xu added a comment -

        fix checked in by Jeramy under revision 1242547

        Show
        Helen Xu added a comment - fix checked in by Jeramy under revision 1242547

          People

          • Assignee:
            Helen Xu
            Reporter:
            Helen Xu
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 4h
              4h
              Remaining:
              Remaining Estimate - 4h
              4h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development