0

Dear all:

I write a sample plugin and i want insert this bundle into my controller. But error occurs when i start it in the OSGI, it show:

gogo: BundleException: The bundle "org.opendaylight.controller.ping.plugin_0.4.0.SNAPSHOT [98]" could not be resolved. Reason: Missing Constraint: Import-Package: org.opendaylight.controller.sal.binding.api; version="[1.1.0,2.0.0)"

Referring from this post page, I think that I've got a newer version of a plug-in without its dependencies.

The error shows that the minimum version number of org.opendaylight.controller.sal.binding.api is 1.1.0, and mine version is 1.0-1 as i lookup in my directory of controller/opendaylight/distribution/opendaylight/target/distribution.opendaylight-osgipackage/opendaylight/plugins.

My question is how to switch the version from 1.0-1 to 1.1, i can find the 1.1 version of sal.binding.api in my directory: ~/.m2/repository/org/opendaylight/controller/sal-binding-api/1.1-SNAPSHOT.

As i look into my pom.xml, i foud my dependency is 1.1:

<dependency>
      <groupId>org.opendaylight.controller</groupId>
      <artifactId>sal-binding-api</artifactId>
      <version>1.1-SNAPSHOT</version>
    </dependency>

I think it's very strange.

Great appreciation for anyone's reply!

Best Regards,
Vinllen

Community
  • 1
  • 1
vinllen
  • 1,369
  • 2
  • 18
  • 36

2 Answers2

0

Plugin versions should be in the form 'major.minor.micro.build', where 'major', 'minor' and 'micro' are all numbers, 'build' can be anything. So you should have something like 1.1.0.SNAPSHOT.

greg-449
  • 109,219
  • 232
  • 102
  • 145
0

I have solved this problem: change the version 1.1 to 1.0-1 in pom.xml. After then , if have any other problems, change the version 1.1 to 1.0-1 with the different jar packet continue.

vinllen
  • 1,369
  • 2
  • 18
  • 36