commit | 173204690b035f1b9be36022c9dfd64f1f264123 | [log] [tgz] |
---|---|---|
author | Pier <pierluigi.ventre@cnit.it> | Fri Apr 20 14:14:34 2018 +0200 |
committer | Pier <pierluigi.ventre@cnit.it> | Mon Apr 23 08:45:46 2018 +0200 |
tree | 2ed2f3594fd1a153844b7720a8534b8dff838286 | |
parent | 6be77d81a62fce50e6b2e4fb0f3c284a57720700 [diff] |
Improve Mcast termination Change-Id: I2855d28b374af821667e08bb3baec01f5cfd8100
diff --git a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastHandler.java b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastHandler.java index 50d0969d..3b659bd 100644 --- a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastHandler.java +++ b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastHandler.java
@@ -351,7 +351,12 @@ * Clean up when deactivating the application. */ public void terminate() { + mcastEventCache.invalidateAll(); executorService.shutdown(); + mcastNextObjStore.destroy(); + mcastRoleStore.destroy(); + mcastUtils.terminate(); + log.info("Terminated"); } /** @@ -372,7 +377,6 @@ } } - /** * Process the ROUTE_ADDED event. *
diff --git a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastUtils.java b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastUtils.java index fc89fde..2b13370 100644 --- a/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastUtils.java +++ b/apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/mcast/McastUtils.java
@@ -93,6 +93,13 @@ } /** + * Clean up when deactivating the application. + */ + public void terminate() { + mcastLeaderCache.clear(); + } + + /** * Get router mac using application config and the connect point. * * @param deviceId the device id