You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by Trevor Stevens <ts...@me.com> on 2013/07/14 21:53:30 UTC

persistence-context-ref elements are not picked up from web-fragement.xml

When loading a webapp with a jar containing a web-fragment.xml and persistence.xml I am unable to access the persistence-context from JNDI that was defined in the web-fragment.xml. However if I move the exact same persistence-context-ref configuration to the web.xml everything works as expected. Is TomEE not merging the web.xml/web-fragment.xml files properly?

Test case for this issue: https://www.dropbox.com/s/5ae5eibuaaemu4o/persistenceref-webfragment.zip

Thanks,
Trevor Stevens
tstevens@me.com



Re: persistence-context-ref elements are not picked up from web-fragement.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi

thanks for the sample,

it was an issue on tomee side:
https://issues.apache.org/jira/browse/TOMEE-1002

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/7/14 Trevor Stevens <ts...@me.com>

> When loading a webapp with a jar containing a web-fragment.xml and
> persistence.xml I am unable to access the persistence-context from JNDI
> that was defined in the web-fragment.xml. However if I move the exact same
> persistence-context-ref configuration to the web.xml everything works as
> expected. Is TomEE not merging the web.xml/web-fragment.xml files properly?
>
> Test case for this issue:
> https://www.dropbox.com/s/5ae5eibuaaemu4o/persistenceref-webfragment.zip
>
> Thanks,
> Trevor Stevens
> tstevens@me.com
>
>
>