diff --git a/src/main/java/net/floodlightcontroller/core/internal/Controller.java b/src/main/java/net/floodlightcontroller/core/internal/Controller.java index 827cfdb40705c7df72c4b78ad02ac2c338186203..3368269cfca1380a53e041da2599dae8de56c313 100644 --- a/src/main/java/net/floodlightcontroller/core/internal/Controller.java +++ b/src/main/java/net/floodlightcontroller/core/internal/Controller.java @@ -1047,15 +1047,15 @@ public class Controller implements IFloodlightProviderService, SwitchUpdateType.ACTIVATED)); sendNotificationsIfSwitchDiffers(storedSwitch, sw); counters.syncedSwitchActivated.updateCounterWithFlush(); - if (this.syncedSwitches.isEmpty()) { - // we have just activated the last synced switch. I.e., - // all previously known switch are now active. Send - // notification - // update dispatcher will increment counter - addUpdateToQueue(new ReadyForReconcileUpdate()); - } } addSwitchToStore(sw); + if (this.syncedSwitches.isEmpty()) { + // we have just activated the last synced switch. I.e., + // all previously known switch are now active. Send + // notification + // update dispatcher will increment counter + addUpdateToQueue(new ReadyForReconcileUpdate()); + } } /**