openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rick Curtis (JIRA)" <j...@apache.org>
Subject [jira] Updated: (OPENJPA-932) Runtime enhancer doesn't work propery if there is a trailing persistence.xml file on the classpath.
Date Wed, 11 Mar 2009 14:42:50 GMT

     [ https://issues.apache.org/jira/browse/OPENJPA-932?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Rick Curtis updated OPENJPA-932:
--------------------------------

    Attachment: OPENJPA-932-unitTest-resources.jar
                OPENJPA-932-unitTest.patch

For the unit test I needed to have multiple META-INF/persistence.xml files on my classpath
and the test validates that all PUs are found that exist in those xml files. I wasn't quite
sure what the 'proper' way was to do this, but what I posted works... Please correct me if
there is a better way.

Note: The attached jar file needs to be expanded into openjpa-parent\openjpa-persistence\src\test.

-Rick

> Runtime enhancer doesn't work propery if there is a trailing persistence.xml file on
the classpath.
> ---------------------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-932
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-932
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: kernel
>    Affects Versions: 1.2.0, 2.0.0-M1, 2.0.0
>            Reporter: Rick Curtis
>         Attachments: OPENJPA-932-2.0.patch, OPENJPA-932-2.0.patch, OPENJPA-932-unitTest-resources.jar,
OPENJPA-932-unitTest.patch
>
>
> I have an application where I am using runtime class enhancement via the javaagent and
I set openjpa.RuntimeUnenhancedClasses=unsupported. My application works fine when running
on 1.1.0 but when I moved to 1.2.0 (and 2.0.0) I started getting errors because my classes
aren't being enhanced. 
> After debugging I determined that I had a jar on the end of my classpath that had a META-INF/persistence.xml
file in it. The extra persistence.xml file has no PUs defined, and should have been ignored.
When I removed that jar from my classpath things starting working again. It also works if
I put my META-INF/persistence.xml file on the end of my classpath.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message