catch and log cluster singleton service registration exceptions
[groupbasedpolicy.git] / neutron-ovsdb / src / main / java / org / opendaylight / controller / config / yang / config / neutron_ovsdb / impl / NeutronOvsdbInstance.java
index 07f3fb460f7a5c40b4a626ad919ef4b3b3c028d8..6e8d74a9146956fca40856ba8ddbf9dd907a6340 100644 (file)
@@ -49,7 +49,11 @@ public class NeutronOvsdbInstance implements ClusterSingletonService, AutoClosea
 
     public void initialize() {
         LOG.info("Clustering session initiated for {}", this.getClass().getSimpleName());
-        singletonServiceRegistration = clusterSingletonService.registerClusterSingletonService(this);
+        try {
+            singletonServiceRegistration = clusterSingletonService.registerClusterSingletonService(this);
+        } catch (Exception e) {
+            LOG.warn("Exception thrown while registering cluster singleton service in {}", this.getClass(), e.getMessage());
+        }
     }
 
     @Override