Hi,

i think it is intentional, we want it to work case insentively

*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/3/27 AndyG <[email protected]>

> org.apache.openejb.config.AutoConfig#findResourceId uses
> 'equalsIgnoreCase'.
>
> I doubt this is correct for at least DataSources as 'dsBob' is not the same
> as 'dsBOB' - Not sure about other resource IDs.
>
> I came across this specifically undeploying an app with say 'Bob' and then
> deploying a new app named 'BOB' (With corresponding DataSources). The old
> datasource names are still found (for the unbound resource) and the new
> resource name is replaced - This then leads to an exception.
>
> Adjusting PersistenceUnit unit-BOB <jta-data-source> to Resource ID
> 'opv_Bob' from 'opv_BOB'
>
> ...
>
> javax.naming.NameNotFoundException: Name "openejb/Resource/dsBOB" not
> found.
>         at
> org.apache.openejb.core.ivm.naming.IvmContext.federate(IvmContext.java:197)
>         at
> org.apache.openejb.core.ivm.naming.IvmContext.lookup(IvmContext.java:151)
>         at
>
> org.apache.openejb.assembler.classic.PersistenceBuilder.createEntityManagerFactory(PersistenceBuilder.java:85)
>
> The old resource name is obviously not removed from some list/map - Which
> is
> another issue (minor leak I guess). However, a case sensitive
> org.apache.openejb.config.AutoConfig#findResourceId fixes the blocker.
>
> Andy.
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/Case-insensitive-org-apache-openejb-config-AutoConfig-findResourceId-tp4661818.html
> Sent from the OpenEJB Dev mailing list archive at Nabble.com.
>

Reply via email to