Hello and thanks for your response.
I've tried that also. I've tried to run a simple Spring MVC app on top of Tomcat (that itself is deployed as a bundle in Equinox). What I have now is an Equinox config.ini that looks like this
Code:
eclipse.ignoreApp=true
osgi.noShutdown=true
osgi.console=
osgi.clean=true
osgi.bundles=com.springsource.slf4j.api.jar@start,\
com.springsource.slf4j.org.apache.commons.logging.jar@start,\
com.springsource.slf4j.log4j.jar,\
log4j.configuration-1.2.1.jar,\
log4j.osgi.jar@start,\
com.springsource.org.aopalliance.jar@start,\
com.springsource.net.sf.cglib.jar@start,\
org.springframework.aop.jar@start,\
org.springframework.beans.jar@start,\
org.springframework.core.jar@start,\
org.springframework.context.jar@start,\
org.springframework.web.jar@start,\
org.springframework.web.servlet.jar@start,\
com.springsource.javax.servlet.jar@start,\
jsp-api.osgi.jar@start,\
commons-el.osgi.jar@start,\
jstl.osgi.jar@start,\
jasper.osgi.jar@start,\
com.springsource.mx4j.jar@start,\
catalina.osgi.jar@start,\
catalina.start.osgi.jar@start,\
spring-osgi-io.jar@start,\
spring-osgi-core.jar@start,\
spring-osgi-extender.jar@start,\
spring-osgi-web.jar@start,\
spring-osgi-web-extender.jar@start,\
webapps/helloosgi.war@start
My war file has in it's manifest file:
Code:
Import-Package: org.springframework.stereotype,org.springframework.web
.bind.annotation,org.springframework.web.servlet,org.springframework.osgi.web
And in my war's web.xml the servlet element is:
Code:
<servlet>
<servlet-name>HelloOsgi</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<load-on-startup>1</load-on-startup>
<init-param>
<param-name>contextClass</param-name>
<param-value>org.springframework.osgi.web.context.support.OsgiBundleXmlWebApplicationContext</param-value>
</init-param>
</servlet>
In this scenario I get the same thing when I try to start the bundle. Class not found exception (OsgiBundleXmlWebApplicationContext). So it's definitely a dependency issue. I haven't tried with Spring DM 2, but I have a hunch I will get the same thing. I think the problem is in my configuration.
Thank you,
Mihai