I have been unable to get the struts convention plugin to work on
JBoss 5.1.
If I set
<constant name="struts.convention.exclude.parentClassLoader"
value="true" />
as per the convention plugin documentation, and debug through the
setup code, I notice that the WEB-INF/classes directory in my war
(which is deployed in an ear) gets removed from the set of URL's to
search for action classes.
Switching that constant to 'false' allows the WEB-INF/classes
directory to remain in the set of URL's, but then I get this error
when it attempts to load the war:
2010-07-09 22:14:03,102 ERROR [CommonsLogger.java:27] : Unable to read
URL [vfszip:/<JBOSS_HOME_DIR>/server/default/deploy/myapp.ear/myapp-
web.war/WEB-INF/classes/]
java.io.FileNotFoundException: /< JBOSS_HOME_DIR>/server/default/
deploy/myapp.ear/myapp-web.war/WEB-INF/classes
at
org
.jboss
.net.protocol.file.FileURLConnection.connect(FileURLConnection.java:105)
at
org
.jboss
.net
.protocol.file.FileURLConnection.getInputStream(FileURLConnection.java:
112)
at java.net.URL.openStream(URL.java:1007)
at
com.opensymphony.xwork2.util.finder.ClassFinder.jar(ClassFinder.java:
464)
at
com
.opensymphony.xwork2.util.finder.ClassFinder.<init>(ClassFinder.java:
129)
at
org
.apache
.struts2
.convention
.PackageBasedActionConfigBuilder
.findActions(PackageBasedActionConfigBuilder.java:352)
at
org
.apache
.struts2
.convention
.PackageBasedActionConfigBuilder
.buildActionConfigs(PackageBasedActionConfigBuilder.java:317)
at
org
.apache
.struts2
.convention
.ClasspathPackageProvider.loadPackages(ClasspathPackageProvider.java:53)
Is there some magical configuration setting I am missing? or does this
just not work on JBoss 5.1 when deploying inside of an ear?
Thanks,
Scott