You can see that there is a problem on OC4J!!!
http://forum.springframework.org/archive/index.php/t-27179.html
classpath* while powerful is restricted by the classloader.getResource()
implementation. Some application servers behave correctly, others don't. To
maximize the reuse across various platform, as Injecteer suggested, try to
use a pattern as exact as possible without wildcard matching.
If you still depend on the classpath* for your environment then try using it
with the WARs unpacked.
--------------------------------------------------------------------------------
volenin
07-23-2006, 01:56 PM
For the record:
- the problem seems to be in a _webapplication_ class loader itself, ie,
Tomcat loads resource from lib/jar files no problem, while OC4J - does not
- Java 1.4.2 system class loader has no problem loading resource by the path
specified from the jar files
- the problem for JVM system classloader present only paths which _root
starts_ with 'asteriks', ie: "classpath*:**/myres.xml" - in this case the
classloader behaves as described in the docs
- a simple way to test whether your classloader hierarhy will support loaded
resources from WEB-INF/lib JAR files or not is to check if you'll get an
empty enumeration for the call: yourClassLoader.getResources("mypackage"),
providing the jar file contains 'mypackage/**' directory hierarhy
- some debugging shows that the problem with OC4J seems to be that webapp
classloader doesn't pass the request to the system classloader on one hand,
and doesn't do proper traversing of JAR file on another hand
So, I believe normally there shouldn't be a problem loading resources from
WEB-INF/lib jar files, but smth in OC4J prevents it.
That's why I actually wonder if it's worthwhile for Spring to have its own
'failover' ClassLoader to load resources, which would be a bit more 'cross
platform' and doesn't rely that heavily on the underlying ClassLoader
hierarhies...
Thanks for your advices - the exact path does work, though, again, from what
I saw during debugging, the 'patterned' path should have worked as well...
diana2 wrote:
I'm deployng geo 1.5.2. on OC4J 10.1.2
After deploy (war file) when I run geoserver I received the error:
07/12/12 11:23:53 Oracle Application Server Containers for J2EE 10g
(10.1.2.0.2)
initialized
12 dic 11:24:34 ERROR [context.ContextLoader] - Context initialization
failed
org.springframework.beans.factory.BeanDefinitionStoreException: Could not
resolv
e bean definition resource pattern [classpath*:/applicationContext.xml];
nested
exception is java.net.MalformedURLException: unknown protocol: jndi
java.net.MalformedURLException: unknown protocol: jndi
in the forum
http://www.nabble.com/spring-framework-problem-to8277834.html#a8296688
I don't find HOW resolve it
Thanks
Diana
--
View this message in context: http://www.nabble.com/Deploy-on-OC4J-tp14292662p14298285.html
Sent from the GeoServer - Dev mailing list archive at Nabble.com.