From 02013b33111f0b51d07c80c89f4d5d08b60b2099 Mon Sep 17 00:00:00 2001 From: Dan Timoney Date: Thu, 4 Feb 2021 16:36:06 -0500 Subject: Update for ODL Aluminum Update A1 adapter to conform to OpenDaylight Aluminum. Issue-ID: CCSDK-3138 Signed-off-by: Dan Timoney Change-Id: I1dbda465c93ca8d4da532764b36c9ffb41fc7a9a --- .../features/a1/adapter/A1AdapterProvider.java | 16 ++++---- .../OSGI-INF/blueprint/impl-blueprint.xml | 46 ---------------------- .../org/opendaylight/blueprint/impl-blueprint.xml | 6 +-- 3 files changed, 10 insertions(+), 58 deletions(-) delete mode 100644 a1-adapter/a1-adapter-api/provider/src/main/resources/OSGI-INF/blueprint/impl-blueprint.xml (limited to 'a1-adapter/a1-adapter-api/provider/src/main') diff --git a/a1-adapter/a1-adapter-api/provider/src/main/java/org/onap/ccsdk/features/a1/adapter/A1AdapterProvider.java b/a1-adapter/a1-adapter-api/provider/src/main/java/org/onap/ccsdk/features/a1/adapter/A1AdapterProvider.java index 8693f493..40dfcbc5 100644 --- a/a1-adapter/a1-adapter-api/provider/src/main/java/org/onap/ccsdk/features/a1/adapter/A1AdapterProvider.java +++ b/a1-adapter/a1-adapter-api/provider/src/main/java/org/onap/ccsdk/features/a1/adapter/A1AdapterProvider.java @@ -30,9 +30,8 @@ import java.util.Properties; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import org.onap.ccsdk.sli.core.sli.provider.MdsalHelper; -import org.opendaylight.controller.md.sal.binding.api.NotificationPublishService; -import org.opendaylight.controller.sal.binding.api.BindingAwareBroker; -import org.opendaylight.controller.sal.binding.api.RpcProviderRegistry; +import org.opendaylight.mdsal.binding.api.NotificationPublishService; +import org.opendaylight.mdsal.binding.api.RpcProviderService; import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.A1ADAPTERAPIService; import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.DeleteA1PolicyInput; import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.DeleteA1PolicyInputBuilder; @@ -55,6 +54,7 @@ import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.PutA1PolicyInp import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.PutA1PolicyOutput; import org.opendaylight.yang.gen.v1.org.onap.a1.adapter.rev200122.PutA1PolicyOutputBuilder; import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.concepts.ObjectRegistration; import org.opendaylight.yangtools.yang.common.RpcResult; import org.opendaylight.yangtools.yang.common.RpcResultBuilder; import org.slf4j.Logger; @@ -82,24 +82,24 @@ public class A1AdapterProvider implements AutoCloseable, A1ADAPTERAPIService { private final ExecutorService executor; protected NotificationPublishService notificationService; - protected RpcProviderRegistry rpcRegistry; - protected BindingAwareBroker.RpcRegistration rpcRegistration; + protected RpcProviderService rpcService; private final A1AdapterClient a1AdapterClient; + private ObjectRegistration rpcRegistration; public A1AdapterProvider(final NotificationPublishService notificationPublishService, - final RpcProviderRegistry rpcProviderRegistry, final A1AdapterClient a1AdapterClient) { + final RpcProviderService rpcProviderService, final A1AdapterClient a1AdapterClient) { log.info("Creating provider for {}", APPLICATION_NAME); executor = Executors.newFixedThreadPool(1); this.notificationService = notificationPublishService; - this.rpcRegistry = rpcProviderRegistry; + this.rpcService = rpcProviderService; this.a1AdapterClient = a1AdapterClient; initialize(); } public void initialize() { log.info("Initializing provider for {}", APPLICATION_NAME); - rpcRegistration = rpcRegistry.addRpcImplementation(A1ADAPTERAPIService.class, this); + rpcRegistration = rpcService.registerRpcImplementation(A1ADAPTERAPIService.class, this); log.info("Initialization complete for {}", APPLICATION_NAME); } diff --git a/a1-adapter/a1-adapter-api/provider/src/main/resources/OSGI-INF/blueprint/impl-blueprint.xml b/a1-adapter/a1-adapter-api/provider/src/main/resources/OSGI-INF/blueprint/impl-blueprint.xml deleted file mode 100644 index 28dfb5e4..00000000 --- a/a1-adapter/a1-adapter-api/provider/src/main/resources/OSGI-INF/blueprint/impl-blueprint.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/a1-adapter/a1-adapter-api/provider/src/main/resources/org/opendaylight/blueprint/impl-blueprint.xml b/a1-adapter/a1-adapter-api/provider/src/main/resources/org/opendaylight/blueprint/impl-blueprint.xml index 28dfb5e4..825ecc17 100644 --- a/a1-adapter/a1-adapter-api/provider/src/main/resources/org/opendaylight/blueprint/impl-blueprint.xml +++ b/a1-adapter/a1-adapter-api/provider/src/main/resources/org/opendaylight/blueprint/impl-blueprint.xml @@ -31,11 +31,9 @@ + interface="org.opendaylight.mdsal.binding.api.NotificationPublishService" /> - + -- cgit 1.2.3-korg