OpenJPA
  1. OpenJPA
  2. OPENJPA-788

Error finding entity class while parsing orm.xml.

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.0.0, 1.0.1, 1.0.2, 1.0.3, 1.1.0, 1.2.0
    • Fix Version/s: None
    • Component/s: jpa
    • Labels:
      None
    • Environment:
      WebLogic Server 10.0 MP1, Oracle Database

      Description

      There is an error loading entity class while parsing object-relational mapping XML file with classloader. It uses environment classloader instead of application classloader to load entity class when object-relational mapping XML file is parsed.

      OPENJPA-40 has introduced a change in PersistenceMetaDataFactory and sets the classloader to envClassLoader if it is not null instead of loader passed as method input parameter and there is NPE fixed with SVN change number 447112 to use envClassLoader only if it not null.

      1. test-src.zip
        4 kB
        Vikram Bhatia
      2. OPENJPA-788.patch
        0.8 kB
        Vikram Bhatia
      3. client.jar
        2 kB
        Vikram Bhatia
      4. app.jar
        4 kB
        Vikram Bhatia

        Activity

        Hide
        Vikram Bhatia added a comment -

        Application to be deployed on WebLogic Server.

        Show
        Vikram Bhatia added a comment - Application to be deployed on WebLogic Server.
        Hide
        Vikram Bhatia added a comment -

        Junit Testcase with main class com.openjpa.simpletest.TestMain.

        Show
        Vikram Bhatia added a comment - Junit Testcase with main class com.openjpa.simpletest.TestMain.
        Hide
        Vikram Bhatia added a comment -

        To reproduce the issue, follow the following steps:
        1. Create data source with JNDI name as txDS.
        2. Deploy application app.jar on WebLogic Server.
        3. Use class com.openjpa.simpletest.TestMain to run the testcase using junit.

        Show
        Vikram Bhatia added a comment - To reproduce the issue, follow the following steps: 1. Create data source with JNDI name as txDS. 2. Deploy application app.jar on WebLogic Server. 3. Use class com.openjpa.simpletest.TestMain to run the testcase using junit.
        Hide
        Vikram Bhatia added a comment -

        Testcase Source Code

        Show
        Vikram Bhatia added a comment - Testcase Source Code
        Hide
        Vikram Bhatia added a comment -

        Proposed Solution.

        Show
        Vikram Bhatia added a comment - Proposed Solution.
        Hide
        Vikram Bhatia added a comment -

        This issue has been resolved by Abe White with SVN 739054.

        Show
        Vikram Bhatia added a comment - This issue has been resolved by Abe White with SVN 739054.
        Hide
        Vikram Bhatia added a comment -

        The fix needs to be merged to branches 0.9.7-r547073 and 1.1.x.

        Show
        Vikram Bhatia added a comment - The fix needs to be merged to branches 0.9.7-r547073 and 1.1.x.

          People

          • Assignee:
            Unassigned
            Reporter:
            Vikram Bhatia
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development