2
votes

I want build a App based on Nitrogen SR1 version, my steps are:

  1. Build a maven project with command: mvn archetype:generate -DarchetypeGroupId=org.opendaylight.controller -DarchetypeArtifactId=opendaylight-startup-archetype -DarchetypeRepository=http://nexus.opendaylight.org/content/repositories/opendaylight.release -DarchetypeCatalog=remote -DarchetypeVersion=1.4.1 enter image description here

  2. groupId: org.opendaylight.hni artifactId: hni enter image description here

  3. After build success ,I build this “hni app” with command: Mvn clean install -DskipTests enter image description here

  4. After build success. I start this “hni app”’s Karaf, and feature
    install hni. Then I went to see log , my two features: Features-hni & odl-hni-api They are both installed. enter image description here enter image description here

  5. But there should be “HniProvider Session Initiated” in this log file. Cuz my code: HniProvider.init() should print these words.
    However,they aren’t be printed in log file. enter image description here

So I want ask Why? When I build a app based on Carbon version, I follow these steps ,too. But the “HniProvider Session Initiated” is be printed in log in Carbon version.

What are the diffences between the Carbon and Nitrogen,when building apps ??? Thx very much .

1
Yang Han, I don't see anything immediately wrong in your steps above. Instead of supporting you here, can I suggest that you subscribe to and ask this on an OpenDaylight mailing list, see lists.opendaylight.org/mailman/listinfo? For example lists.opendaylight.org/mailman/listinfo/controller-dev or lists.opendaylight.org/mailman/listinfo/devvorburger
thank you very muchYang Han

1 Answers

1
votes

The problem is that only the generated odl-X-api feature (odl-hni-api in your case) is installed - so the implementation code that logs that output isn't installed. This is because the features-X pom only lists the odl-X-api feature as a dependency - it needs to also list the odl-X feature which has the implementation bundle, and the odl-X-cli and odl-X-rest features (if you want those). This is fixed in https://git.opendaylight.org/gerrit/#/c/66545/.