From ee0a16926c26d70160b739d49ef48f1c2436f96b Mon Sep 17 00:00:00 2001 From: Alessandro Boch Date: Tue, 14 Jan 2014 15:19:36 -0800 Subject: [PATCH 1/1] FRM should not remove a static flow config on async error report - Currently FRM is removing the affected static flow config on receiving a flow error event from the switch. The correct action is to modify the config status. The config removal was a temporary fix for the flow configuration across cluster (request served by another controller node) when this request was always sent asynchronously. Now it is no longer needed as FRM implements both the synch and async flow rewust across the cluster. Change-Id: If2d473cd4688bdf83ecc0a0f5eb210b938157d29 Signed-off-by: Alessandro Boch --- .../internal/ForwardingRulesManager.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/ForwardingRulesManager.java b/opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/ForwardingRulesManager.java index 2b3347f312..41075b9554 100644 --- a/opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/ForwardingRulesManager.java +++ b/opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/ForwardingRulesManager.java @@ -2994,7 +2994,11 @@ public class ForwardingRulesManager implements // staticFlowEntry should never be null. // the null check is just an extra defensive check. if(staticFlowEntry != null) { - staticFlows.remove(staticFlowEntry.getKey()); + // Modify status and update cluster cache + log.debug("Updating static flow configuration on async error event"); + String status = String.format("Cannot be installed on node. reason: %s", errorString); + staticFlowEntry.getValue().setStatus(status); + refreshClusterStaticFlowsStatus(node); } } } -- 2.36.6