5 Replies Latest reply: Apr 14, 2011 5:59 PM by Joe Thomas RSS

Snowdrop 1.1 error

Joe Thomas Newbie

We're trying out Spring with our JBoss5.0 EAP. My understaning is that by using snowdrop we get better intergration with JBoss and Spring. I downloaded the snowdrop 1.1 distro and unzipped itnto my /{config}/deployers directory:

snowdrop.png

 

I also have a 3rd party poral .war that uses spring internally, I noticed the following exception when starting the server:

Deployment "vfsfile:/C:/jboss-eap-5.0/jboss-as/server/production/deploy/liferay.war/" is in error due to the following reason(s): java.lang.IllegalArgumentException: Multiple matching files not allowed: [ZipEntryHandler@6825008[path=liferay.war/WEB-INF/lib/portal-impl.jar/META-INF/base-spring.xml context=file:/C:/jboss-eap-5.0/jboss-as/server/production/deploy/ real=file:/C:/jboss-eap-5.0/jboss-as/server/production/deploy/liferay.war/WEB-INF/lib/portal-impl.jar/META-INF/base-spring.xml], ZipEntryHandler@18873538[path=liferay.war/WEB-INF/lib/portal-impl.jar/META-INF/counter-spring.xml....etc

 

however, when I add the following stanza to spring-deployers-jboss-beans.xml, the exception is gone:

 

   <bean name="SpringParserDeployer" class="org.jboss.spring.deployers.SpringParserDeployer">

       <property name="allowMultipleFiles">true</property>

   </bean>

 

is this how we go 2 bat if we have multiple spring-based application on Jboss5.0?

  • 1. Snowdrop 1.1 error
    Ales Justin Master
    is this how we go 2 bat if we have multiple spring-based application on Jboss5.0?

    Yes.

    Dunno why we don't have that as default already. Marius?

  • 2. Snowdrop 1.1 error
    Joe Thomas Newbie

    thanks for the quick response...I'll be posting more questions...

  • 3. Snowdrop 1.1 error
    Marius Bogoevici Expert

    If you want your application context to be bootstrapped by JBoss, yes. However, you may not need the deployer if your WARs use a ContextLoaderListener already (look at the web.xml) - as Spring provides that mechanism already for WARs.

  • 4. Snowdrop 1.1 error
    Marius Bogoevici Expert

    The default option should be set up in the deployer definition file, apparently it isn't.

  • 5. Snowdrop 1.1 error
    Joe Thomas Newbie

    Yes it does use its own context loader..dumb question..new to spring so please bear with me...so does "bootstrap" mean that the snowdrop deployer actually deploys the beans in the  spring archives in dropped in  /deploy as "services" accessible from jndi..to all other deployments..whereas the spring beans inside a .war  are not (ie just libraries)...but the snowdrop deployer  seems to scan/find all -spring.xml files in the /deloy directory??....again just started learning Jboss-spring..thnx