On Sep 10, 2010, at 10:25 AM, Faw wrote:

> 
> I'm trying to make a cocoon 2.2 application using m2Eclipse (Maven plugin), I
> created a block+webapp and created a war. When I try to deploy to geronimo
> it says it deploys but it fails to start. The error I get (among a few, but
> I think this is the one responsible) is 'Could not open ServletContext
> resource [/WEB-INF/applicationContext.xml]' even though the file is in the
> war. The full error message and stack trace is:

Do you have a pointer to a war file (sample app) that exhibits this problem?

Are you sure that the war file contains WEB-INF/applicationContext.xml and the 
xml file is not in a different location?

You can be sure there's not interference between the version of spring packaged 
in your war file and the version of spring used by geronimo, you can try the 
following deployment plan (e.g. ./deploy.sh deploy <your-app> nospring.xml). 
Where nospring.xml contains:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web-1.1"; 
xmlns:dep="http://geronimo.apache.org/xml/ns/deployment-1.1"; 
xmlns:naming="http://geronimo.apache.org/xml/ns/naming-1.1";>
  <dep:environment>
    <dep:moduleId>
      <dep:groupId>org.mygroup</dep:groupId>
      <dep:artifactId>MyApp</dep:artifactId>
      <dep:version>1.1</dep:version>
      <dep:type>car</dep:type>
    </dep:moduleId>
    <!-- 
         Don't load spring classes or resources from parent ClassLoaders.
      -->
    <dep:hidden-classes>
      <dep:filter>org.springframework.</dep:filter>
      <dep:filter>META-INF/spring</dep:filter>
    </dep:hidden-classes>
    <dep:inverse-classloading/>
  </dep:environment>
</web-app>

--kevan

Reply via email to