Merge "Fix for openflow devices not connecting to controller"
authorArunprakash D <d.arunprakash@ericsson.com>
Thu, 10 Sep 2020 04:08:15 +0000 (04:08 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Thu, 10 Sep 2020 04:08:15 +0000 (04:08 +0000)
1  2 
applications/forwardingrules-manager/src/main/java/org/opendaylight/openflowplugin/applications/frm/util/FrmUtil.java

index bc926b87fdd00966f66caed49e5110d5a0776581,5eda39b1cdf8ed3e13e6b9dfdbde90edaaa1cb71..4093180395582a622f7617247c51b5c2c6853b1e
@@@ -58,7 -58,6 +58,7 @@@ public final class FrmUtil 
      private static final Logger LOG = LoggerFactory.getLogger(FrmUtil.class);
      private static final String SEPARATOR = ":";
      private static final long RPC_RESULT_TIMEOUT = 2500;
 +    public static final String OPENFLOW_PREFIX = "openflow:";
  
      private static final String JMX_OBJ_NAME_LIST_OF_SHRDS = "org.opendaylight.controller:type="
              + "DistributedConfigDatastore,Category=ShardManager,name=shard-manager-config";
                      actions = ((WriteActionsCase)instruction.getInstruction())
                              .getWriteActions().nonnullAction().values();
                  }
-                 for (Action action : actions) {
-                     if (action.getAction().implementedInterface()
-                             .equals(ActionType.GROUP_ACTION.getActionType())) {
-                         return ((GroupActionCase) action.getAction()).getGroupAction()
-                                 .getGroupId();
+                 if (actions != null) {
+                     for (Action action : actions) {
+                         if (action.getAction().implementedInterface().equals(ActionType.GROUP_ACTION.getActionType())) {
+                             return ((GroupActionCase) action.getAction()).getGroupAction().getGroupId();
+                         }
                      }
                  }
              }