|Deploying a WAB with Spring Security 3.0.5 in bundle-classpath [message #756334]
||Sat, 12 November 2011 02:51
Registered: December 2010
I'm bundling my maven project as a wab, using the maven-bundle-plugin. The wab contain spring-security-config3.0.5.RELEASE in WEB-INF/lib folder. |
When start the bundle on the osgi shell, I get the following exception.
org.springframework.beans.FatalBeanException: Class [org.springframework.security.config.SecurityNamespaceHandler] for namespace [www.springframework.org/schema/security] does not implement the [org.springframework.beans.factory.xml.NamespaceHandler] interface
I did a clhas through the shell on the SecurityNamespaceHandler class and my module seems to be the only one which has the class
I did a clload on the same class again and this time, the bundle started without any exceptions and was put to the ACTIVE state.
Questions I have,
1. Virgo uses spring 3.0. Does it have an older version of SecurityNamespaceHandler class in its path? The reason I ask this is because, digging through some code, it seems like the xmlbean factory looks for the class in a specific class loader. I'm not packaging the spring modules (packaging only the security modules) and use spring services provided by virgo. If that is the case, the class in my bundle class path may not have been loaded.
2. If Case1 is true, should i package spring with my app and stop using the provided spring framework?
Powered by FUDForum
. Page generated in 0.01791 seconds