From: Tony Tkacik Date: Fri, 21 Aug 2015 10:40:27 +0000 (+0200) Subject: Moved binding MD-SAL APIs to binding folder X-Git-Tag: release/beryllium~143 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=ffb48e89507f417d52b7a86d6c34f9af7f955477;p=mdsal.git Moved binding MD-SAL APIs to binding folder Renamed artefacts: sal-binding-api to mdsal-binding-api sal-binding-broker to mdsal-binding-dom-adapter sal-binding-util to mdsal-binding-util Removed deprecated Hydrogen and Helium interfaces and adapters, since they still can be provided from original location. Change-Id: I0ebbfc2e927aa6c036e9be7ed216a48d970e66d0 Signed-off-by: Tony Tkacik --- diff --git a/opendaylight/md-sal/sal-binding-api/.gitignore b/binding/mdsal-binding-api/.gitignore similarity index 100% rename from opendaylight/md-sal/sal-binding-api/.gitignore rename to binding/mdsal-binding-api/.gitignore diff --git a/opendaylight/md-sal/sal-binding-api/pom.xml b/binding/mdsal-binding-api/pom.xml similarity index 78% rename from opendaylight/md-sal/sal-binding-api/pom.xml rename to binding/mdsal-binding-api/pom.xml index c70115e7e3..a6f3025fc8 100644 --- a/opendaylight/md-sal/sal-binding-api/pom.xml +++ b/binding/mdsal-binding-api/pom.xml @@ -2,11 +2,12 @@ 4.0.0 - org.opendaylight.controller - sal-parent - 1.3.0-SNAPSHOT + org.opendaylight.mdsal + mdsal-binding + 0.8.0-SNAPSHOT - sal-binding-api + mdsal-binding-api + 2.0.0-SNAPSHOT bundle @@ -15,15 +16,15 @@ guava - org.opendaylight.controller - sal-common-api + org.opendaylight.mdsal + mdsal-common-api org.opendaylight.yangtools concepts - org.opendaylight.yangtools + org.opendaylight.mdsal yang-binding diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingService.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingService.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingTransactionChain.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingTransactionChain.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingTransactionChain.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/BindingTransactionChain.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ClusteredDataChangeListener.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ClusteredDataChangeListener.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ClusteredDataChangeListener.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ClusteredDataChangeListener.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataBroker.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataBroker.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataBroker.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataBroker.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataChangeListener.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataChangeListener.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataChangeListener.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataChangeListener.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java similarity index 95% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java index afeb21c530..634a55b258 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataObjectModification.java @@ -66,19 +66,18 @@ public interface DataObjectModification extends org.openda @Nonnull ModificationType getModificationType(); /** - * Returns before-state of top level container. Implementations are encouraged, - * but not required to provide this state. + * Returns before-state of top level container. Implementations are encouraged, but not required + * to provide this state. * - * @param root Class representing data container - * @return State of object before modification. Null if subtree was not present, - * or the implementation cannot provide the state. + * + * @return State of object before modification. Null if subtree was not present, or the + * implementation cannot provide the state. */ @Nullable T getDataBefore(); /** * Returns after-state of top level container. * - * @param root Class representing data container * @return State of object after modification. Null if subtree is not present. */ @Nullable T getDataAfter(); diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeListener.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeListener.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeListener.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeListener.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java similarity index 96% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java index 9d12e44916..6462faf9d6 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeChangeService.java @@ -12,8 +12,7 @@ import org.opendaylight.yangtools.concepts.ListenerRegistration; import org.opendaylight.yangtools.yang.binding.DataObject; /** - * A {@link DOMService} which allows users to register for changes to a - * subtree. + * A {@link BindingService} which allows users to register for changes to a subtree. */ public interface DataTreeChangeService extends BindingService { /** diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java similarity index 97% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java index b86d31b790..2e82582101 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeIdentifier.java @@ -40,7 +40,7 @@ public final class DataTreeIdentifier implements Immutable } /** - * Return the {@link YangInstanceIdentifier} of the root node. + * Return the {@link InstanceIdentifier} of the root node. * * @return Instance identifier corresponding to the root node. */ diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeModification.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeModification.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeModification.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/DataTreeModification.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPoint.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPoint.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPoint.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPoint.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPointService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPointService.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPointService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/MountPointService.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java similarity index 78% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java index 5ec51269b7..41856e1f85 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationPublishService.java @@ -51,37 +51,32 @@ public interface NotificationPublishService extends BindingService { void putNotification(Notification notification) throws InterruptedException; /** - * Publishes a notification to subscribed listeners. This initiates - * the process of sending the notification, but delivery to the - * listeners can happen asynchronously, potentially after a call to - * this method returns. + * Publishes a notification to subscribed listeners. This initiates the process of sending the + * notification, but delivery to the listeners can happen asynchronously, potentially after a + * call to this method returns. * * Still guaranteed not to block. Returns Listenable Future which will complete once. * - * @param notification - * the notification to publish. + * @param notification the notification to publish. * @return A listenable future which will report completion when the service has finished - * propagating the notification to its immediate registrants, or {@value #REJECTED} if resource - * constraints prevent + * propagating the notification to its immediate registrants, or {@link #REJECTED} if + * resource constraints prevent * @throws NullPointerException if the notification is null */ ListenableFuture offerNotification(Notification notification); /** - * Publishes a notification to subscribed listeners. This initiates - * the process of sending the notification, but delivery to the - * listeners can happen asynchronously, potentially after a call to - * this method returns. This method is guaranteed not to block more - * than the specified timeout. + * Publishes a notification to subscribed listeners. This initiates the process of sending the + * notification, but delivery to the listeners can happen asynchronously, potentially after a + * call to this method returns. This method is guaranteed not to block more than the specified + * timeout. * - * @param notification - * the notification to publish. + * @param notification the notification to publish. * @param timeout how long to wait before giving up, in units of unit - * @param unit a TimeUnit determining how to interpret the - * timeout parameter + * @param unit a TimeUnit determining how to interpret the timeout parameter * @return A listenable future which will report completion when the service has finished - * propagating the notification to its immediate registrants, or {@value #REJECTED} if resource - * constraints prevent + * propagating the notification to its immediate registrants, or {@link #REJECTED} if + * resource constraints prevent * @throws InterruptedException if interrupted while waiting * @throws NullPointerException if the notification or unit is null * @throws IllegalArgumentException if timeout is negative. diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationRejectedException.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationRejectedException.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationRejectedException.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationRejectedException.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java similarity index 59% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java index ba352359cc..b1b9b1b2af 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/NotificationService.java @@ -13,26 +13,27 @@ import org.opendaylight.yangtools.yang.binding.NotificationListener; /** * Notification broker which allows clients to subscribe for and publish YANG-modeled notifications. * - * Each YANG module which defines notifications results in a generated interface {ModuleName}Listener - * which handles all the notifications defined in the YANG model. Each notification type translates to - * a specific method of the form on{NotificationType} on the generated interface. - * The generated interface also extends the - * {@link org.opendaylight.yangtools.yang.binding.NotificationListener} interface and implementations - * are registered using {@link #registerNotificationListener(org.opendaylight.yangtools.yang.binding.NotificationListener)} + * Each YANG module which defines notifications results in a generated interface + * {ModuleName}Listener which handles all the notifications defined in the YANG model. + * Each notification type translates to a specific method of the form + * on{NotificationType} on the generated interface. The generated interface also + * extends the {@link org.opendaylight.yangtools.yang.binding.NotificationListener} interface and + * implementations are registered using + * {@link #registerNotificationListener(org.opendaylight.yangtools.yang.binding.NotificationListener)} * method. * - *
Dispatch Listener Example
+ * Dispatch Listener Example *

* Lets assume we have following YANG model: * *

  * module example {
  *      ...
- *
+ * 
  *      notification start {
  *          ...
  *      }
- *
+ * 
  *      notification stop {
  *           ...
  *      }
@@ -40,31 +41,39 @@ import org.opendaylight.yangtools.yang.binding.NotificationListener;
  * 
* * The generated interface will be: + * *
- *  public interface ExampleListener extends NotificationListener {
- *      void onStart(Start notification);
- *      void onStop(Stop notification);
- *  }
+ * public interface ExampleListener extends NotificationListener {
+ *     void onStart(Start notification);
+ * 
+ *     void onStop(Stop notification);
+ * }
  * 
+ * * The following defines an implementation of the generated interface: + * *
- *  public class MyExampleListener implements ExampleListener {
- *      public void onStart(Start notification) {
- *          // do something
- *      }
- *
- *      public void onStop(Stop notification) {
- *          // do something
- *      }
- *  }
+ * public class MyExampleListener implements ExampleListener {
+ *     public void onStart(Start notification) {
+ *         // do something
+ *     }
+ * 
+ *     public void onStop(Stop notification) {
+ *         // do something
+ *     }
+ * }
  * 
+ * * The implementation is registered as follows: + * *
- *  MyExampleListener listener = new MyExampleListener();
- *  ListenerRegistration reg = service.registerNotificationListener( listener );
+ * MyExampleListener listener = new MyExampleListener();
+ * ListenerRegistration<NotificationListener> reg = service.registerNotificationListener(listener);
  * 
- * The onStart method will be invoked when someone publishes a Start notification and - * the onStop method will be invoked when someone publishes a Stop notification. + * + * The onStart method will be invoked when someone publishes a Start + * notification and the onStop method will be invoked when someone publishes a + * Stop notification. */ public interface NotificationService extends BindingService { /** diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadOnlyTransaction.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadOnlyTransaction.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadOnlyTransaction.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadOnlyTransaction.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadTransaction.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadTransaction.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadTransaction.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadTransaction.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadWriteTransaction.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadWriteTransaction.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadWriteTransaction.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/ReadWriteTransaction.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/TransactionFactory.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/TransactionFactory.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/TransactionFactory.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/TransactionFactory.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/WriteTransaction.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/WriteTransaction.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/WriteTransaction.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/md/sal/binding/api/WriteTransaction.java diff --git a/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareConsumer.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareConsumer.java new file mode 100644 index 0000000000..890ac762fd --- /dev/null +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareConsumer.java @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.controller.sal.binding.api; + +import org.osgi.framework.BundleContext; + +@Deprecated +public abstract class AbstractBindingAwareConsumer extends AbstractBrokerAwareActivator implements BindingAwareConsumer { + + @Override + protected final void onBrokerAvailable(final BindingAwareBroker broker, final BundleContext context) { + broker.registerConsumer(this); + } + + /** + * Called when this bundle is started (before + * {@link #onSessionInitialized(org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext)} + * so the Framework can perform the bundle-specific activities necessary to start this bundle. + * This method can be used to register services or to allocate any resources that this bundle + * needs. + * + *

+ * This method must complete and return to its caller in a timely manner. + * + * @param context The execution context of the bundle being started. + * @throws Exception If this method throws an exception, this bundle is marked as stopped and + * the Framework will remove this bundle's listeners, unregister all services registered + * by this bundle, and release all services used by this bundle. + */ + @Override + protected void startImpl(final BundleContext context) throws Exception { + // NOOP + } +} diff --git a/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareProvider.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareProvider.java new file mode 100644 index 0000000000..6f9cd56173 --- /dev/null +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBindingAwareProvider.java @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.controller.sal.binding.api; + +import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext; +import org.osgi.framework.BundleContext; + +@Deprecated +public abstract class AbstractBindingAwareProvider extends AbstractBrokerAwareActivator implements BindingAwareProvider { + + @Override + protected final void onBrokerAvailable(final BindingAwareBroker broker, final BundleContext context) { + final ProviderContext ctx = broker.registerProvider(this); + } + + /** + * Called when this bundle is started (before {@link #onSessionInitiated(ProviderContext)} so + * the Framework can perform the bundle-specific activities necessary to start this bundle. This + * method can be used to register services or to allocate any resources that this bundle needs. + * + *

+ * This method must complete and return to its caller in a timely manner. + * + * @param context The execution context of the bundle being started. + * @throws Exception If this method throws an exception, this bundle is marked as stopped and + * the Framework will remove this bundle's listeners, unregister all services registered + * by this bundle, and release all services used by this bundle. + */ + @Override + protected void startImpl(final BundleContext context) throws Exception { + // NOOP + } +} diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java similarity index 58% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java index bd78c584ee..dede5e81ba 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/AbstractBrokerAwareActivator.java @@ -9,7 +9,6 @@ package org.opendaylight.controller.sal.binding.api; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; - import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; import org.osgi.framework.ServiceReference; @@ -22,10 +21,10 @@ public abstract class AbstractBrokerAwareActivator implements BundleActivator { private BundleContext context; private ServiceTracker tracker; private BindingAwareBroker broker; - private ServiceTrackerCustomizer customizer = new ServiceTrackerCustomizer() { + private final ServiceTrackerCustomizer customizer = new ServiceTrackerCustomizer() { @Override - public BindingAwareBroker addingService(ServiceReference reference) { + public BindingAwareBroker addingService(final ServiceReference reference) { broker = context.getService(reference); mdActivationPool.execute(new Runnable() { @@ -38,13 +37,13 @@ public abstract class AbstractBrokerAwareActivator implements BundleActivator { } @Override - public void modifiedService(ServiceReference reference, BindingAwareBroker service) { + public void modifiedService(final ServiceReference reference, final BindingAwareBroker service) { removedService(reference, service); addingService(reference); } @Override - public void removedService(ServiceReference reference, BindingAwareBroker service) { + public void removedService(final ServiceReference reference, final BindingAwareBroker service) { broker = context.getService(reference); mdActivationPool.execute(new Runnable() { @@ -59,7 +58,7 @@ public abstract class AbstractBrokerAwareActivator implements BundleActivator { @Override - public final void start(BundleContext context) throws Exception { + public final void start(final BundleContext context) throws Exception { this.context = context; startImpl(context); tracker = new ServiceTracker<>(context, BindingAwareBroker.class, customizer); @@ -70,31 +69,12 @@ public abstract class AbstractBrokerAwareActivator implements BundleActivator { @Override - public final void stop(BundleContext context) throws Exception { + public final void stop(final BundleContext context) throws Exception { tracker.close(); stopImpl(context); } - - /** - * Called when this bundle is started (before - * {@link #onSessionInitiated(ProviderContext)} so the Framework can perform - * the bundle-specific activities necessary to start this bundle. This - * method can be used to register services or to allocate any resources that - * this bundle needs. - * - *

- * This method must complete and return to its caller in a timely manner. - * - * @param context - * The execution context of the bundle being started. - * @throws Exception - * If this method throws an exception, this bundle is marked as - * stopped and the Framework will remove this bundle's - * listeners, unregister all services registered by this bundle, - * and release all services used by this bundle. - */ - protected void startImpl(BundleContext context) { + protected void startImpl(final BundleContext context) throws Exception { // NOOP } @@ -110,19 +90,15 @@ public abstract class AbstractBrokerAwareActivator implements BundleActivator { * This method must complete and return to its caller in a timely manner. * * @param context The execution context of the bundle being stopped. - * @throws Exception If this method throws an exception, the bundle is still - * marked as stopped, and the Framework will remove the bundle's - * listeners, unregister all services registered by the bundle, and - * release all services used by the bundle. */ - protected void stopImpl(BundleContext context) { + protected void stopImpl(final BundleContext context) { // NOOP } protected abstract void onBrokerAvailable(BindingAwareBroker broker, BundleContext context); - protected void onBrokerRemoved(BindingAwareBroker broker, BundleContext context) { + protected void onBrokerRemoved(final BindingAwareBroker broker, final BundleContext context) { stopImpl(context); } } diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java similarity index 54% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java index ab62c803e2..ec90e70cb4 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareBroker.java @@ -7,112 +7,77 @@ */ package org.opendaylight.controller.sal.binding.api; -import org.opendaylight.controller.md.sal.common.api.routing.RoutedRegistration; + + import org.opendaylight.yangtools.concepts.ObjectRegistration; import org.opendaylight.yangtools.yang.binding.BaseIdentity; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; import org.opendaylight.yangtools.yang.binding.RpcService; -import org.osgi.framework.BundleContext; /** * Binding-aware core of the SAL layer responsible for wiring the SAL consumers. * - * The responsibility of the broker is to maintain registration of SAL - * functionality {@link Consumer}s and {@link Provider}s, store provider and - * consumer specific context and functionality registration via - * {@link ConsumerContext} and provide access to infrastructure services, which - * removes direct dependencies between providers and consumers. + * The responsibility of the broker is to maintain registration of SAL functionality + * {@link BindingAwareConsumer}s and {@link BindingAwareProvider}s, store provider and consumer + * specific context and functionality registration via + * {@link org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext} and + * provide access to infrastructure services, which removes direct dependencies between providers + * and consumers. * - * The Binding-aware broker is also responsible for translation from Java - * classes modeling the functionality and data to binding-independent form which - * is used in SAL Core. + * The Binding-aware broker is also responsible for translation from Java classes modeling the + * functionality and data to binding-independent form which is used in SAL Core. * * - *

Infrastructure services

Some examples of infrastructure services: - * - *
    - *
  • YANG Module service - see {@link ConsumerContext#getRpcService(Class)}, - * {@link ProviderContext} - *
  • Notification Service - see {@link NotificationService} and - * {@link NotificationProviderService} - *
  • Functionality and Data model - *
  • Data Store access and modification - see {@link org.opendaylight.controller.sal.binding.api.data.DataBrokerService} and - * {@link org.opendaylight.controller.sal.binding.api.data.DataProviderService} - *
- * - * The services are exposed via session. + *

Infrastructure services

Some examples of infrastructure services: The services are + * exposed via session. * *

Session-based access

* - * The providers and consumers needs to register in order to use the - * binding-independent SAL layer and to expose functionality via SAL layer. + * The providers and consumers needs to register in order to use the binding-independent SAL layer + * and to expose functionality via SAL layer. * - * For more information about session-based access see {@link ConsumerContext} - * and {@link ProviderContext} + * For more information about session-based access see + * {@link org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext} and + * {@link ProviderContext} */ public interface BindingAwareBroker { - /* - * @deprecated Use registerConsumer(BindingAwareConsumer cons) instead (BundleContext is no longer used) - */ - @Deprecated - ConsumerContext registerConsumer(BindingAwareConsumer consumer, BundleContext ctx); /** * Registers the {@link BindingAwareConsumer}, which will use the SAL layer. * *

- * Note that consumer could register additional functionality at later point - * by using service and functionality specific APIs. + * Note that consumer could register additional functionality at later point by using service + * and functionality specific APIs. * *

- * The consumer is required to use returned session for all communication - * with broker or one of the broker services. The session is announced to - * the consumer by invoking - * {@link Consumer#onSessionInitiated(ConsumerContext)}. + * The consumer is required to use returned session for all communication with broker or one of + * the broker services. The session is announced to the consumer by invoking + * {@link BindingAwareConsumer#onSessionInitialized(org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext)}. * - * @param cons - * Consumer to be registered. + * @param consumer Consumer to be registered. * @return a session specific to consumer registration - * @throws IllegalArgumentException - * If the consumer is null. - * @throws IllegalStateException - * If the consumer is already registered. + * @throws IllegalArgumentException If the consumer is null. + * @throws IllegalStateException If the consumer is already registered. */ ConsumerContext registerConsumer(BindingAwareConsumer consumer); - /* - * @deprecated Use registerProvider(BindingAwareProvider prov) instead (BundleContext is no longer used) - */ - @Deprecated - ProviderContext registerProvider(BindingAwareProvider provider, BundleContext ctx); - /** * Registers the {@link BindingAwareProvider}, which will use the SAL layer. * *

- * During the registration, the broker obtains the initial functionality - * from consumer, using the - * {@link BindingAwareProvider#getImplementations()}, and register that - * functionality into system and concrete infrastructure services. - * - *

- * Note that provider could register additional functionality at later point - * by using service and functionality specific APIs. + * Note that provider could register additional functionality at later point by using service + * and functionality specific APIs. * *

- * The consumer is required to use returned session for all - * communication with broker or one of the broker services. The session is - * announced to the consumer by invoking + * The consumer is required to use returned session for all communication with broker or + * one of the broker services. The session is announced to the consumer by invoking * {@link BindingAwareProvider#onSessionInitiated(ProviderContext)}. * * - * @param prov - * Provider to be registered. + * @param provider Provider to be registered. * @return a session unique to the provider registration. - * @throws IllegalArgumentException - * If the provider is null. - * @throws IllegalStateException - * If the consumer is already registered. + * @throws IllegalArgumentException If the provider is null. + * @throws IllegalStateException If the consumer is already registered. */ ProviderContext registerProvider(BindingAwareProvider provider); @@ -120,14 +85,13 @@ public interface BindingAwareBroker { * {@link BindingAwareConsumer} specific access to the SAL functionality. * *

- * ConsumerSession is {@link BindingAwareConsumer}-specific access to the - * SAL functionality and infrastructure services. + * ConsumerSession is {@link BindingAwareConsumer}-specific access to the SAL functionality and + * infrastructure services. * *

- * The session serves to store SAL context (e.g. registration of - * functionality) for the consumer and provides access to the SAL - * infrastructure services and other functionality provided by - * {@link Provider}s. + * The session serves to store SAL context (e.g. registration of functionality) for the consumer + * and provides access to the SAL infrastructure services and other functionality provided by + * providers. */ public interface ConsumerContext extends RpcConsumerRegistry { @@ -181,35 +145,28 @@ public interface BindingAwareBroker { /** * Represents a routed RPC implementation registration. Users should call the - * {@link RoutedRegistration#close close} method when the registration is no longer needed. + * {@link RpcRegistration#close() close} method when the registration is no longer needed. * * @param the implemented RPC service interface */ - public interface RoutedRpcRegistration extends RpcRegistration, - RoutedRegistration, InstanceIdentifier, T> { + public interface RoutedRpcRegistration extends RpcRegistration { /** * Register particular instance identifier to be processed by this * RpcService * - * Deprecated in favor of {@link RoutedRegistration#registerPath(Object, Object)}. - * * @param context * @param instance */ - @Deprecated - void registerInstance(Class context, InstanceIdentifier instance); + void registerPath(Class context, InstanceIdentifier instance); /** * Unregister particular instance identifier to be processed by this * RpcService * - * Deprecated in favor of {@link RoutedRegistration#unregisterPath(Object, Object)}. - * * @param context * @param instance */ - @Deprecated - void unregisterInstance(Class context, InstanceIdentifier instance); + void unregisterPath(Class context, InstanceIdentifier instance); } } diff --git a/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareConsumer.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareConsumer.java new file mode 100644 index 0000000000..c309971a3b --- /dev/null +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareConsumer.java @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.controller.sal.binding.api; + +import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext; + +/** +* +* A developer implemented component that gets registered with the Broker. +* +*/ +public interface BindingAwareConsumer { + + /** + * Callback signaling initialization of the consumer session to the SAL. + * + * The consumer MUST use the session for all communication with SAL or + * retrieving SAL infrastructure services. + * + * This method is invoked by + * {@link BindingAwareBroker#registerConsumer(BindingAwareConsumer)} + * + * @param session + * Unique session between consumer and SAL. + */ + void onSessionInitialized(ConsumerContext session); + +} diff --git a/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareProvider.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareProvider.java new file mode 100644 index 0000000000..fb92e64614 --- /dev/null +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareProvider.java @@ -0,0 +1,132 @@ +/* + * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.controller.sal.binding.api; + +import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext; + +/** + * + * A developer implemented component that gets registered with the Broker. + * + * Semantically, a provider may: + * + *

    + *
  1. Emit Notifications
  2. + *
  3. Provide the implementation of RPCs
  4. + *
  5. Write to the operational data tree
  6. + *
+ * + * + *

+ * + * In addition, a BindingAwareProvider can in pursuit of its goals: + * + *

    + *
  1. Subscribe for Notifications
  2. + *
  3. Invoke RPCs
  4. + *
  5. Read from either the operational or config data tree
  6. + *
  7. Write to the config data tree
  8. + *
+ * (All of the above are things a Consumer can also do). + * + *

+ * + * Examples: + * + *

+ * + * To get a NotificationService: + * + *

+ * {code
+ * public void onSessionInitiated(ProviderContext session) {
+ *      NotificationProviderService notificationService = session.getSALService(NotificationProviderService.class);
+ * }
+ * }
+ * 
+ * + * + * + * To register an RPC implementation: + * + *
+ * {code
+ * public void onSessionInitiated(ProviderContext session) {
+ *    RpcRegistration<MyService> registration = session.addRpcImplementation(MyService.class, myImplementationInstance);
+ * }
+ * }
+ * 
+ * + *

+ * + * Where MyService.class is a Service interface generated from a yang model with RPCs modeled in it + * and myImplementationInstance is an instance of a class that implements MyService. + * + * To register a Routed RPC Implementation: + * + *

+ * {code
+ * public void onSessionInitiated(ProviderContext session) {
+ *   RoutedRpcRegistration<SalFlowService> flowRegistration = session.addRoutedRpcImplementation(SalFlowService.class, salFlowServiceImplementationInstance);
+ *      flowRegistration.registerPath(NodeContext.class, nodeInstanceId);
+ * }
+ * }
+ * 
+ * + * Where SalFlowService.class is a Service interface generated from a yang model with RPCs modeled + * in it and salFlowServiceImplementationInstance is an instance of a class that implements + * SalFlowService. + *

+ * The line: + * + *

+ * {code
+ * flowRegistration.registerPath(NodeContext.class, nodeInstanceId);
+ * }
+ * 
+ * + * Is indicating that the RPC implementation is registered to handle RPC invocations that have their + * NodeContext pointing to the node with instance id nodeInstanceId. This bears a bit of further + * explanation. RoutedRPCs can be 'routed' to an implementation based upon 'context'. 'context' is a + * pointer (instanceId) to some place in the data tree. In this example, the 'context' is a pointer + * to a Node. In this way, a provider can register its ability to provide a service for a particular + * Node, but not *all* Nodes. The Broker routes the RPC by 'context' to the correct implementation, + * without the caller having to do extra work. Because of this when a RoutedRPC is registered, it + * needs to also be able to indicate for which 'contexts' it is providing an implementation. + * + * An example of a Routed RPC would be an updateFlow(node, flow) that would be routed based on node + * to the provider which had registered to provide it *for that node*. + * + *

+ * + * To get a DataBroker to allow access to the data tree: + * + *

+ * {code
+ * public void onSessionInitiated(final ProviderContext session) {
+ *      DataBroker databroker = session.getSALService(BindingDataBroker.class);
+ * }
+ * }
+ * 
+ * + * + */ +public interface BindingAwareProvider { + + /** + * Callback signaling initialization of the consumer session to the SAL. + * + * The consumer MUST use the session for all communication with SAL or retrieving SAL + * infrastructure services. + * + * This method is invoked by {@link BindingAwareBroker#registerProvider(BindingAwareProvider)} + * + * @param session Unique session between consumer and SAL. + */ + void onSessionInitiated(ProviderContext session); +} diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareService.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareService.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareService.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/BindingAwareService.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/NotificationListener.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/NotificationListener.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/NotificationListener.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/NotificationListener.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcAvailabilityListener.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcAvailabilityListener.java similarity index 100% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcAvailabilityListener.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcAvailabilityListener.java diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java similarity index 65% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java index 0c5e7649f8..a7a0281157 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcConsumerRegistry.java @@ -22,48 +22,49 @@ public interface RpcConsumerRegistry extends BindingAwareService, BindingService * Returns an implementation of a requested RPC service. * *

- * The returned instance is not an actual implementation of the RPC service - * interface, but a proxy implementation of the interface that forwards to - * an actual implementation, if any. + * The returned instance is not an actual implementation of the RPC service interface, but a + * proxy implementation of the interface that forwards to an actual implementation, if any. *

* * The following describes the behavior of the proxy when invoking RPC methods: *

    - *
  • If an actual implementation is registered with the MD-SAL, all invocations are - * forwarded to the registered implementation.
  • - *
  • If no actual implementation is registered, all invocations will fail by - * throwing {@link IllegalStateException}.
  • - *
  • Prior to invoking the actual implementation, the method arguments are are validated. - * If any are invalid, an {@link IllegalArgumentException} is thrown. + *
  • If an actual implementation is registered with the MD-SAL, all invocations are forwarded + * to the registered implementation.
  • + *
  • If no actual implementation is registered, all invocations will fail by throwing + * {@link IllegalStateException}.
  • + *
  • Prior to invoking the actual implementation, the method arguments are are validated. If + * any are invalid, an {@link IllegalArgumentException} is thrown. *
* - * The returned proxy is automatically updated with the most recent - * registered implementation. + * The returned proxy is automatically updated with the most recent registered implementation. *

- * The generated RPC method APIs require implementors to return a {@link java.util.concurrent.Future Future} - * instance that wraps the {@link org.opendaylight.yangtools.yang.common.RpcResult RpcResult}. Since - * RPC methods may be implemented asynchronously, callers should avoid blocking on the + * The generated RPC method APIs require implementors to return a + * {@link java.util.concurrent.Future Future} instance that wraps the + * {@link org.opendaylight.yangtools.yang.common.RpcResult RpcResult}. Since RPC methods may be + * implemented asynchronously, callers should avoid blocking on the * {@link java.util.concurrent.Future Future} result. Instead, it is recommended to use * {@link com.google.common.util.concurrent.JdkFutureAdapters#listenInPoolThread(java.util.concurrent.Future)} - * or {@link com.google.common.util.concurrent.JdkFutureAdapters#listenInPoolThread(java.util.concurrent.Future, java.util.concurrent.Executor)} + * or + * {@link com.google.common.util.concurrent.JdkFutureAdapters#listenInPoolThread(java.util.concurrent.Future, java.util.concurrent.Executor)} * to listen for Rpc Result. This will asynchronously listen for future result in executor and * will not block current thread. * *

-     *   final Future> future = someRpcService.someRpc( ... );
-     *   Futures.addCallback(JdkFutureAdapters.listenInThreadPool(future), new FutureCallback>() {
-     *
-     *       public void onSuccess(RpcResult result) {
+     *   final Future<RpcResult<SomeRpcOutput>> future = someRpcService.someRpc( ... );
+     *   Futures.addCallback(JdkFutureAdapters.listenInThreadPool(future), new FutureCallback<RpcResult<SomeRpcOutput>>() {
+     * 
+     *       public void onSuccess(RpcResult<SomeRpcOutput> result) {
      *          // process result ...
      *       }
-     *
+     * 
      *       public void onFailure(Throwable t) {
      *          // RPC failed
      *       }
      *   );
      * 
- * @param serviceInterface the interface of the RPC Service. Typically this is an interface generated - * from a YANG model. + * + * @param serviceInterface the interface of the RPC Service. Typically this is an interface + * generated from a YANG model. * @return the proxy for the requested RPC service. This method never returns null. */ T getRpcService(Class serviceInterface); diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java similarity index 59% rename from opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java rename to binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java index 22db985ba9..a24c0ff5a8 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java +++ b/binding/mdsal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/RpcProviderRegistry.java @@ -7,16 +7,13 @@ */ package org.opendaylight.controller.sal.binding.api; -import org.opendaylight.controller.md.sal.common.api.routing.RouteChangePublisher; import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.RoutedRpcRegistration; import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.RpcRegistration; -import org.opendaylight.controller.sal.binding.api.rpc.RpcContextIdentifier; -import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; import org.opendaylight.yangtools.yang.binding.RpcService; /** - * Provides a registry for Remote Procedure Call (RPC) service implementations. The RPCs are - * defined in YANG models. + * Provides a registry for Remote Procedure Call (RPC) service implementations. The RPCs are defined + * in YANG models. *

* There are 2 types of RPCs: *