geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jarek Gawor (JIRA)" <j...@apache.org>
Subject [jira] Commented: (GERONIMO-5606) Bad persistenceUnitRoot for PUs in jars embedded in WARs
Date Tue, 14 Sep 2010 00:28:35 GMT

    [ https://issues.apache.org/jira/browse/GERONIMO-5606?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12909067#action_12909067
] 

Jarek Gawor commented on GERONIMO-5606:
---------------------------------------

This actually gets pretty tricky. OpenJPA uses the classloader to discover all META-INF/orm.xml
files and tries to compare them against persistenceUnitRoot of the PU to make sure that given
orm.xml belongs to the right PU. The URLs returned by classloader.getResources() are "bundle"
type of URLs as generated by the framework. Now, in PersistenceUnitGBean we know which embedded
jar file contains the PU but there is no easy way to generate a proper "bundle" type of url
using the Bundle API. And if we can't generate a proper persistenceUnitRoot URL, OpenJPA will
fail to discover the orm.xml and possibly other resources.


> Bad persistenceUnitRoot for PUs in jars embedded in WARs
> --------------------------------------------------------
>
>                 Key: GERONIMO-5606
>                 URL: https://issues.apache.org/jira/browse/GERONIMO-5606
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: persistence
>    Affects Versions: 3.0
>            Reporter: Jarek Gawor
>            Assignee: Jarek Gawor
>             Fix For: 3.0
>
>
> The persistenceUnitRoot for PUs in jars embedded in WARs is computed incorrectly which
for example causes the META-INF/orm.xml files not to be discovered by OpenJPA.

-- 
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