From 10b6a72f544dd1331e9dba53e77c61deaafbd19f Mon Sep 17 00:00:00 2001 From: Dan Timoney Date: Thu, 22 Feb 2018 17:22:31 -0600 Subject: Nitrogen port: sli/northbound Update sli/northbound to compile for ODL Nitrogen Change-Id: Ib14fea5dd3922175bd183afb9f3c85edaa7a2f0c Issue-ID: CCSDK-177 Signed-off-by: Dan Timoney --- asdcApi/features/ccsdk-asdcApi/pom.xml | 47 +++++++ asdcApi/features/features-asdcApi/pom.xml | 29 ++++ asdcApi/features/pom.xml | 150 +++------------------ asdcApi/features/src/main/resources/features.xml | 38 ------ asdcApi/installer/pom.xml | 32 +++-- .../src/main/resources/scripts/install-feature.sh | 9 +- asdcApi/model/pom.xml | 84 ++---------- asdcApi/pom.xml | 48 ++----- asdcApi/provider/pom.xml | 46 +++---- .../sli/northbound/asdcapi/TestAsdcApiApi.java | 9 +- 10 files changed, 162 insertions(+), 330 deletions(-) create mode 100644 asdcApi/features/ccsdk-asdcApi/pom.xml create mode 100644 asdcApi/features/features-asdcApi/pom.xml delete mode 100644 asdcApi/features/src/main/resources/features.xml (limited to 'asdcApi') diff --git a/asdcApi/features/ccsdk-asdcApi/pom.xml b/asdcApi/features/ccsdk-asdcApi/pom.xml new file mode 100644 index 000000000..061e5edc8 --- /dev/null +++ b/asdcApi/features/ccsdk-asdcApi/pom.xml @@ -0,0 +1,47 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + single-feature-parent + 1.0.1-SNAPSHOT + + + + org.onap.ccsdk.sli.northbound + ccsdk-asdcApi + 0.2.1-SNAPSHOT + feature + + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} + + + + + org.opendaylight.controller + odl-mdsal-broker + xml + features + + + org.onap.ccsdk.sli.core + ccsdk-sli + ${ccsdk.sli.core.version} + xml + features + + + ${project.groupId} + asdcApi-model + ${project.version} + + + ${project.groupId} + asdcApi-provider + ${project.version} + + + + diff --git a/asdcApi/features/features-asdcApi/pom.xml b/asdcApi/features/features-asdcApi/pom.xml new file mode 100644 index 000000000..2ac8f59d8 --- /dev/null +++ b/asdcApi/features/features-asdcApi/pom.xml @@ -0,0 +1,29 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + feature-repo-parent + 1.0.1-SNAPSHOT + + + + org.onap.ccsdk.sli.northbound + features-asdcApi + 0.2.1-SNAPSHOT + feature + + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} + + + + ${project.groupId} + ccsdk-asdcApi + ${project.version} + xml + features + + + + diff --git a/asdcApi/features/pom.xml b/asdcApi/features/pom.xml index 73cc0dd12..5b940021c 100755 --- a/asdcApi/features/pom.xml +++ b/asdcApi/features/pom.xml @@ -1,131 +1,23 @@ - - 4.0.0 - - asdcApi - org.onap.ccsdk.sli.northbound - 0.2.0-SNAPSHOT - - asdcApi-features - - jar - - - - org.onap.ccsdk.sli.northbound - asdcApi-model - ${project.version} - - - org.onap.ccsdk.sli.northbound - asdcApi-provider - ${project.version} - - - - org.opendaylight.mdsal - features-mdsal - ${odl.mdsal.features.version} - features - xml - - - runtime - - - - - - - org.opendaylight.controller - opendaylight-karaf-empty - ${odl.karaf.empty.distro.version} - zip - - - - - - org.opendaylight.odlparent - features-test - test - ${odl.commons.opendaylight.version} - - - - org.opendaylight.yangtools - features-yangtools - ${odl.yangtools.version} - features - xml - runtime - - - - - - - true - src/main/resources - - - - - org.apache.maven.plugins - maven-resources-plugin - - - filter - - resources - - generate-resources - - - - - - org.codehaus.mojo - build-helper-maven-plugin - - - attach-artifacts - - attach-artifact - - package - - - - ${project.build.directory}/classes/${features.file} - xml - features - - - - - - - - + + 4.0.0 + + + org.onap.ccsdk.parent + odlparent-lite + 1.0.1-SNAPSHOT + + + org.onap.ccsdk.sli.northbound + asdcApi-features + 0.2.1-SNAPSHOT + pom + + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} + + + ccsdk-asdcApi + features-asdcApi + diff --git a/asdcApi/features/src/main/resources/features.xml b/asdcApi/features/src/main/resources/features.xml deleted file mode 100644 index 0f7fe3b8d..000000000 --- a/asdcApi/features/src/main/resources/features.xml +++ /dev/null @@ -1,38 +0,0 @@ - - - - - - - mvn:org.opendaylight.mdsal/features-mdsal/${odl.mdsal.features.version}/xml/features - - - - odl-mdsal-broker - - mvn:org.onap.ccsdk.sli.northbound/asdcApi-model/${project.version} - mvn:org.onap.ccsdk.sli.northbound/asdcApi-provider/${project.version} - - sdnc-sli - - - diff --git a/asdcApi/installer/pom.xml b/asdcApi/installer/pom.xml index 1b7666935..aac236bde 100755 --- a/asdcApi/installer/pom.xml +++ b/asdcApi/installer/pom.xml @@ -1,19 +1,25 @@ 4.0.0 + - asdcApi - org.onap.ccsdk.sli.northbound - 0.2.0-SNAPSHOT + org.onap.ccsdk.parent + odlparent-lite + 1.0.1-SNAPSHOT + + + org.onap.ccsdk.sli.northbound asdcApi-installer - asdcApi - Karaf Installer + 0.2.1-SNAPSHOT pom + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} + - sdnc-asdcApi - sdnc-asdcApi - mvn:org.onap.ccsdk.sli.northbound/asdcApi-features/${project.version}/xml/features + ccsdk-asdcApi + ${application.name} + mvn:org.onap.ccsdk.sli.northbound/${features.boot}/${project.version}/xml/features false @@ -21,10 +27,10 @@ org.onap.ccsdk.sli.northbound - asdcApi-features + ${application.name} ${project.version} - features xml + features * @@ -32,7 +38,11 @@ - + + org.onap.ccsdk.sli.northbound + asdcApi-model + ${project.version} + org.onap.ccsdk.sli.northbound asdcApi-provider @@ -100,7 +110,6 @@ false false org.onap.ccsdk.sli.northbound - sli-common,sli-provider,dblib-provider provided @@ -135,5 +144,4 @@ - diff --git a/asdcApi/installer/src/main/resources/scripts/install-feature.sh b/asdcApi/installer/src/main/resources/scripts/install-feature.sh index e986764b9..cee4a4952 100644 --- a/asdcApi/installer/src/main/resources/scripts/install-feature.sh +++ b/asdcApi/installer/src/main/resources/scripts/install-feature.sh @@ -10,9 +10,9 @@ # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at -# +# # http://www.apache.org/licenses/LICENSE-2.0 -# +# # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -23,7 +23,6 @@ ODL_HOME=${ODL_HOME:-/opt/opendaylight/current} ODL_KARAF_CLIENT=${ODL_KARAF_CLIENT:-${ODL_HOME}/bin/client} -ODL_KARAF_CLIENT_OPTS=${ODL_KARAF_CLIENT_OPTS:-"-u karaf"} INSTALLERDIR=$(dirname $0) REPOZIP=${INSTALLERDIR}/${features.boot}-${project.version}.zip @@ -36,5 +35,5 @@ else exit 1 fi -${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:repo-add ${features.repositories} -${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:install ${features.boot} +${ODL_KARAF_CLIENT} feature:repo-add ${features.repositories} +${ODL_KARAF_CLIENT} feature:install ${features.boot} diff --git a/asdcApi/model/pom.xml b/asdcApi/model/pom.xml index a3b94f54f..27e5905b9 100755 --- a/asdcApi/model/pom.xml +++ b/asdcApi/model/pom.xml @@ -1,92 +1,32 @@ - + 4.0.0 + - asdcApi - org.onap.ccsdk.sli.northbound - 0.2.0-SNAPSHOT + org.onap.ccsdk.parent + binding-parent + 1.0.1-SNAPSHOT + + org.onap.ccsdk.sli.northbound asdcApi-model - 0.2.0-SNAPSHOT + 0.2.1-SNAPSHOT bundle - + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} - - - org.apache.felix - maven-bundle-plugin - true - - - * - - - - - org.opendaylight.yangtools - yang-maven-plugin - ${odl.yangtools.yang.maven.plugin.version} - - - org.opendaylight.mdsal - maven-sal-api-gen-plugin - ${odl.sal.api.gen.plugin.version} - jar - - - org.opendaylight.netconf - sal-rest-docgen-maven - ${odl.restconf.version} - jar - - - - - - generate-sources - - - ${yang.file.directory} - - - org.opendaylight.mdsal.binding.maven.api.gen.plugin.CodeGeneratorImpl - ${salGeneratorPath} - - - org.opendaylight.netconf.sal.rest.doc.maven.StaticDocGenerator - target/swagger - - - true - - - - - - - - org.opendaylight.mdsal - yang-binding - ${odl.mdsal.yang.binding.version} - - - org.opendaylight.yangtools - yang-common - ${odl.yangtools.version} - + org.opendaylight.mdsal.model ietf-inet-types - ${odl.ietf-inet-types.version} org.opendaylight.mdsal.model ietf-yang-types - ${odl.ietf-yang-types.version} + + diff --git a/asdcApi/pom.xml b/asdcApi/pom.xml index 932569b09..78c2fcb6b 100755 --- a/asdcApi/pom.xml +++ b/asdcApi/pom.xml @@ -1,51 +1,20 @@ - + 4.0.0 - org.onap.ccsdk.sli.northbound - ccsdk-sli-northbound - 0.2.0-SNAPSHOT + org.onap.ccsdk.parent + odlparent-lite + 1.0.1-SNAPSHOT + - pom org.onap.ccsdk.sli.northbound asdcApi - 0.2.0-SNAPSHOT - - - asdcApi - - - - - - - org.onap.ccsdk.sli.northbound - asdcApi-features - features - xml - ${project.version} - - - - org.onap.ccsdk.sli.northbound - asdcApi-model - ${project.version} - - - - org.onap.ccsdk.sli.northbound - asdcApi-provider - ${project.version} - - - - - - - + 0.2.1-SNAPSHOT + pom + ccsdk-sli-northbound :: asdcApi model @@ -54,4 +23,5 @@ installer + diff --git a/asdcApi/provider/pom.xml b/asdcApi/provider/pom.xml index 9382b9d8a..3f33af028 100755 --- a/asdcApi/provider/pom.xml +++ b/asdcApi/provider/pom.xml @@ -1,23 +1,22 @@ - + 4.0.0 + - asdcApi - org.onap.ccsdk.sli.northbound - 0.2.0-SNAPSHOT + org.onap.ccsdk.parent + binding-parent + 1.0.1-SNAPSHOT + + + org.onap.ccsdk.sli.northbound asdcApi-provider + 0.2.1-SNAPSHOT bundle - - - - org.apache.felix - maven-bundle-plugin - true - - - + ccsdk-sli-northbound :: asdcApi :: ${project.artifactId} + @@ -25,60 +24,49 @@ asdcApi-model ${project.version} - - org.opendaylight.controller - config-api - ${odl.controller.config.api.version} - org.opendaylight.controller sal-binding-config - ${odl.mdsal.version} + org.opendaylight.controller sal-binding-api - ${odl.mdsal.version} + org.opendaylight.controller sal-common-util - ${odl.mdsal.version} + org.onap.ccsdk.sli.core sli-common - ${sdnctl.sli.version} org.onap.ccsdk.sli.core sli-provider - ${sdnctl.sli.version} org.opendaylight.controller sal-test-model - ${odl.mdsal.version} test org.opendaylight.netconf sal-rest-connector - ${odl.mdsal.version} test org.opendaylight.controller sal-binding-broker-impl - ${odl.mdsal.version} test org.opendaylight.controller sal-binding-broker-impl - ${odl.mdsal.version} test-jar tests test @@ -86,21 +74,19 @@ junit junit - ${junit.version} test org.testng testng - 6.11 test org.mockito mockito-core - ${mockito.version} test + diff --git a/asdcApi/provider/src/test/java/org/onap/ccsdk/sli/northbound/asdcapi/TestAsdcApiApi.java b/asdcApi/provider/src/test/java/org/onap/ccsdk/sli/northbound/asdcapi/TestAsdcApiApi.java index f65bbc045..6ad9a829f 100644 --- a/asdcApi/provider/src/test/java/org/onap/ccsdk/sli/northbound/asdcapi/TestAsdcApiApi.java +++ b/asdcApi/provider/src/test/java/org/onap/ccsdk/sli/northbound/asdcapi/TestAsdcApiApi.java @@ -21,10 +21,12 @@ package org.onap.ccsdk.sli.northbound.asdcapi; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.fail; +import static org.mockito.Mockito.mock; import org.junit.Before; import org.junit.Test; -import org.onap.ccsdk.sli.northbound.asdcapi.AsdcApiProvider; -import org.onap.ccsdk.sli.northbound.asdcapi.AsdcApiSliClient; import org.opendaylight.controller.md.sal.binding.api.DataBroker; import org.opendaylight.controller.md.sal.binding.api.NotificationPublishService; import org.opendaylight.controller.md.sal.binding.test.AbstractConcurrentDataBrokerTest; @@ -35,9 +37,6 @@ import org.opendaylight.yangtools.yang.common.RpcResult; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import static org.junit.Assert.*; -import static org.mockito.Mockito.mock; - public class TestAsdcApiApi extends AbstractConcurrentDataBrokerTest { private AsdcApiProvider asdcApiProvider; -- cgit 1.2.3-korg