Details

    • Type: Sub-task
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: OSGi support
    • Labels:
      None

      Description

      After updating Felix version this error appeared in the pax-exam Weld-OSGi tests:

      ERROR: Bundle org.ops4j.pax.exam [1] Error starting link:classpath:META-INF/links/org.ops4j.pax.exam.link (java.lang.NoSuchMethodError: org.osgi.framework.wiring.BundleWire.getProvider()Lorg/osgi/framework/wiring/BundleRevision;)
      java.lang.NoSuchMethodError: org.osgi.framework.wiring.BundleWire.getProvider()Lorg/osgi/framework/wiring/BundleRevision;
      	at org.apache.felix.framework.BundleRevisionDependencies.addDependent(BundleRevisionDependencies.java:44)
      	at org.apache.felix.framework.StatefulResolver.markResolvedRevisions(StatefulResolver.java:998)
      	at org.apache.felix.framework.StatefulResolver.resolve(StatefulResolver.java:427)
      	at org.apache.felix.framework.Felix.resolveBundleRevision(Felix.java:3967)
      	at org.apache.felix.framework.Felix.startBundle(Felix.java:2037)
      	at org.apache.felix.framework.Felix.setActiveStartLevel(Felix.java:1291)
      	at org.apache.felix.framework.FrameworkStartLevelImpl.run(FrameworkStartLevelImpl.java:304)
      	at java.lang.Thread.run(Thread.java:722)
      

      The problem seems to come from the Felix container: it provides its own version of the class org.osgi.framework.wiring.BundleWire which is différent than the one provided by org.osgi.core. For some reasons, Felix doesn't use its own version but the one provided by org.osgi.core.

      The fix consists in excluding org.osgi.core from maven dependencies so it is not include in pax-exam and felix class path.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                sunix Sun Seng David TAN
                Reporter:
                sunix Sun Seng David TAN
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: