diff --git a/core/api/src/main/java/org/onosproject/event/ListenerRegistry.java b/core/api/src/main/java/org/onosproject/event/ListenerRegistry.java
index c2e1aed..6a570c5 100644
--- a/core/api/src/main/java/org/onosproject/event/ListenerRegistry.java
+++ b/core/api/src/main/java/org/onosproject/event/ListenerRegistry.java
@@ -20,7 +20,6 @@
 import java.util.Set;
 import java.util.concurrent.CopyOnWriteArraySet;
 
-import static com.google.common.base.Preconditions.checkArgument;
 import static com.google.common.base.Preconditions.checkNotNull;
 import static org.slf4j.LoggerFactory.getLogger;
 
@@ -33,8 +32,6 @@
 
     private final Logger log = getLogger(getClass());
 
-    private volatile boolean shutdown = false;
-
     private long lastStart;
     private L lastListener;
 
@@ -61,8 +58,8 @@
      */
     public void removeListener(L listener) {
         checkNotNull(listener, "Listener cannot be null");
-        if (checkForNonRegistrant()) {
-            checkArgument(listeners.remove(listener), "Listener not registered");
+        if (!listeners.remove(listener)) {
+            log.warn("Listener {} not registered", listener);
         }
     }
 
@@ -91,41 +88,13 @@
     }
 
     /**
-     * Predicate indicating whether we should throw an exception if the
-     * argument to {@link #removeListener} is not in the current set of
-     * listeners.
-     * <p>
-     * This default implementation returns <code>true</code>.
-     *
-     * @return true if non-listed listeners should cause exception on remove
-     */
-    protected boolean checkForNonRegistrant() {
-        return true;
-    }
-
-    /**
      * Reports a problem encountered while processing an event.
      *
      * @param event event being processed
      * @param error error encountered while processing
      */
     protected void reportProblem(E event, Throwable error) {
-        if (!shutdown) {
-            log.warn("Exception encountered while processing event " + event, error);
-        }
+        log.warn("Exception encountered while processing event " + event, error);
     }
 
-    /**
-     * Prepares the registry for normal operation.
-     */
-    public void activate() {
-        shutdown = false;
-    }
-
-    /**
-     * Prepares the registry for shutdown.
-     */
-    public void deactivate() {
-        shutdown = true;
-    }
 }
diff --git a/core/api/src/test/java/org/onosproject/event/ListenerRegistryTest.java b/core/api/src/test/java/org/onosproject/event/ListenerRegistryTest.java
index 5645926..8cce641 100644
--- a/core/api/src/test/java/org/onosproject/event/ListenerRegistryTest.java
+++ b/core/api/src/test/java/org/onosproject/event/ListenerRegistryTest.java
@@ -26,13 +26,6 @@
  */
 public class ListenerRegistryTest {
 
-    private static class RelaxedRegistry extends TestListenerRegistry {
-        @Override
-        protected boolean checkForNonRegistrant() {
-            return false;
-        }
-    }
-
     private static final TestEvent FOO_EVENT =
             new TestEvent(TestEvent.Type.FOO, "foo");
     private static final TestEvent BAR_EVENT =
@@ -78,16 +71,4 @@
         assertTrue("BAR not processed", secondListener.events.contains(BAR_EVENT));
     }
 
-    @Test(expected = IllegalArgumentException.class)
-    public void removeNonListenerCausesException() {
-        manager.removeListener(listener);
-    }
-
-    @Test
-    public void removeNonListenerIgnored() {
-        manager = new RelaxedRegistry();
-        manager.removeListener(listener);
-        assertTrue("what?", manager.listeners.isEmpty());
-    }
-
 }
diff --git a/web/gui/src/main/java/org/onosproject/ui/impl/topo/ModelListenerRegistry.java b/web/gui/src/main/java/org/onosproject/ui/impl/topo/ModelListenerRegistry.java
index eacbbaf..ae29da4 100644
--- a/web/gui/src/main/java/org/onosproject/ui/impl/topo/ModelListenerRegistry.java
+++ b/web/gui/src/main/java/org/onosproject/ui/impl/topo/ModelListenerRegistry.java
@@ -59,8 +59,4 @@
         }
     }
 
-    @Override
-    protected boolean checkForNonRegistrant() {
-        return false;
-    }
 }
