Announcement Announcement Module

Spring Dynamic Modules forum decommissioned in favor of Eclipse Gemini Blueprint

With the official first release of Eclipse Gemini Blueprint shipped, the migration of the Spring Dynamic Modules code base to the Eclipse Foundation, as part of the Gemini project, has been completed.

As such, this forum has been decommissioned in favour of the Eclipse Gemini forums.
See more
See less
cannot get simple-web-app to work Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • cannot get simple-web-app to work


    I have tried to get the simple-web-app to work in both spring-dm 1.1.1 and 1.2.0 M1. I followed the readme.txt, and after string osgi via:
    java -jar war/libs/org.eclipse.osgi.jar

    I cannot access:

    Once OSIG started I see the following bundles/state:
    id State Bundle
    0 ACTIVE system.bundle_3.2.2.R32x_v20070118
    1 INSTALLED com.springsource.slf4j.api_1.5.0
    2 INSTALLED 1.5.0
    3 INSTALLED com.springsource.slf4j.log4j_1.5.0
    4 RESOLVED org.springframework.osgi.samples.simplewebapp.logg ing.cfg_0.0.0
    5 ACTIVE org.springframework.osgi.log4j.osgi_1.2.15.SNAPSHO T
    6 ACTIVE
    7 ACTIVE
    8 INSTALLED org.springframework.bundle.spring.aop_2.5.5
    9 INSTALLED org.springframework.bundle.spring.beans_2.5.5
    10 INSTALLED org.springframework.bundle.spring.context_2.5.5
    11 INSTALLED org.springframework.bundle.spring.context.support_ 2.5.5
    12 INSTALLED org.springframework.bundle.spring.core_2.5.5
    13 INSTALLED org.springframework.bundle.spring.web_2.5.5
    14 INSTALLED org.springframework.bundle.spring.webmvc_2.5.5
    15 ACTIVE org.springframework.osgi.servlet-api.osgi_2.5.0.SNAPSHOT
    16 ACTIVE org.springframework.osgi.jsp-api.osgi_2.0.0.SNAPSHOT
    17 ACTIVE org.springframework.osgi.commons-el.osgi_1.0.0.SNAPSHOT
    18 ACTIVE org.springframework.osgi.jstl.osgi_1.1.2.SNAPSHOT
    19 ACTIVE org.springframework.osgi.jasper.osgi_5.5.23.SNAPSH OT
    20 INSTALLED org.springframework.osgi.mx4j.osgi_3.0.2.SNAPSHOT
    21 ACTIVE org.springframework.osgi.catalina.osgi_5.5.23.SNAP SHOT
    22 RESOLVED org.springframework.osgi.catalina.start.osgi_1.0.0
    23 INSTALLED org.springframework.bundle.osgi.core_1.2.0.m1
    24 INSTALLED org.springframework.bundle.osgi.io_1.2.0.m1
    25 INSTALLED org.springframework.bundle.osgi.extender_1.2.0.m1
    26 INSTALLED org.springframework.bundle.osgi.web_1.2.0.m1
    27 INSTALLED org.springframework.bundle.osgi.web.extender_1.2.0 .m1
    28 ACTIVE org.springframework.osgi.samples.simplewebapp_0.0. 0

    I would suspect that IDs 26, and 27 should be in active state, not so?

    When I try to start these bundles, I am getting the following errors:
    osgi> start 26
    org.osgi.framework.BundleException: The bundle could not be resolved. Reason: Missing Constraint: Import-Package: org.apache.commons.logging; version="0.0.0"

    Seems as if there are some missing logging bundles.

    What am I doing wrong here?

    -- Thomas

  • #2
    I forgot to mention that the above issue only exists using Mac OS X 10.5.5. The example works perfectly on linux. Has anybody seen this issue using Mac OS X?
    -- Thomas


    • #3

      So I went ahead and belw away my ~/.m2 maven repository and built the sample again. It builds it with an test error now:

      T E S T S
      Running org.springframework.osgi.samples.simplewebapp.Osgi HttpIntegrationTest
      main INFO [simplewebapp.OsgiHttpIntegrationTest] - Equinox OSGi Platform [3.2.2.R32x_v20070118] started
      main INFO [internal.LocalFileSystemMavenRepository] - Local Maven2 repository used: [/Users/thomas/.m2/repository]
      Tests run: 4, Failures: 0, Errors: 4, Skipped: 0, Time elapsed: 0.874 sec <<< FAILURE!

      Results :

      Tests in error:
      testHtmlPage(org.springframework.osgi.samples.simp lewebapp.OsgiHttpIntegrationTest)
      testHelloServlet(org.springframework.osgi.samples. simplewebapp.OsgiHttpIntegrationTest)
      testResourceServlet(org.springframework.osgi.sampl es.simplewebapp.OsgiHttpIntegrationTest)
      testJSP(org.springframework.osgi.samples.simpleweb app.OsgiHttpIntegrationTest)

      Tests run: 4, Failures: 0, Errors: 4, Skipped: 0

      Thread-0 INFO [simplewebapp.OsgiHttpIntegrationTest] - Shutting down OSGi platform
      [INFO] ------------------------------------------------------------------------
      [INFO] ------------------------------------------------------------------------
      [INFO] There are test failures.

      Please refer to /Users/thomas/Desktop/spring-osgi-1.1.1/src/samples/simple-web-app/integration-test/target/surefire-reports for the individual test results.
      [INFO] ------------------------------------------------------------------------
      [INFO] For more information, run Maven with the -e switch
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 13 seconds
      [INFO] Finished at: Tue Sep 16 14:00:58 PDT 2008
      [INFO] Final Memory: 27M/1016M
      [INFO] ------------------------------------------------------------------------

      However, the sample applicaitn runns now. This must be some maven strangeness.

      -- thomas


      • #4
        Hello Thomas,

        You're right, all your bundles may be in an active state, excepted the fragment bunfles which may be in a resolved state.

        As the package org.apache.commons.logging is missing but you have the (1.5.0) present, I suspect that a dependency of SLF4J is missing. As you are using the Equinox, you can try to run the diag command for the bundle 1.

        If you get the com.springsource.slf4j.api (1.5.0) bundle from the Spring Source repository, I think that you need the following two bundles:
        - (0.9.9)
        - (0.9.9)

        You can begin with these bundles and try to find the other missing dependencies of bundles using the diag command.

        Hope it helps you,