BUG-868: disallow instantiation without executor 88/7588/1
authorRobert Varga <rovarga@cisco.com>
Mon, 2 Jun 2014 11:33:10 +0000 (13:33 +0200)
committerRobert Varga <rovarga@cisco.com>
Mon, 2 Jun 2014 11:56:58 +0000 (13:56 +0200)
This clarifies the deprecated API. As it turns out, instantiation
without an executor should be removed, not the other way around.

Change-Id: I3a2738a4da18ef92d3e8c38d0c12f6df653bd74c
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/impl/NotificationBrokerImpl.java

index 7d844b3bf578c1958b3849e4b4d6841b2fd24ddb..716670f5a38b2960a0c25887360744b149bfad6c 100644 (file)
@@ -36,17 +36,11 @@ public class NotificationBrokerImpl implements NotificationProviderService, Auto
 
     private final ListenerRegistry<NotificationInterestListener> interestListeners =
             ListenerRegistry.create();
-
     private final Multimap<Class<? extends Notification>, NotificationListenerRegistration<?>> listeners =
             Multimaps.synchronizedSetMultimap(HashMultimap.<Class<? extends Notification>, NotificationListenerRegistration<?>>create());
-    private ExecutorService executor;
+    private final ExecutorService executor;
 
-    @Deprecated
     public NotificationBrokerImpl(final ExecutorService executor) {
-        this.setExecutor(executor);
-    }
-
-    public void setExecutor(final ExecutorService executor) {
         this.executor = Preconditions.checkNotNull(executor);
     }