BUG 3292: Fix in MatchType for in_port 38/20938/1
authorVishal Thapar <vishal.thapar@ericsson.com>
Fri, 22 May 2015 07:34:57 +0000 (13:04 +0530)
committerVishal Thapar <vishal.thapar@ericsson.com>
Fri, 22 May 2015 07:34:57 +0000 (13:04 +0530)
1. Replace getMatchValues with getBigMatchValues
2. Log stacktrace, not just exception for NPE in install/remove flow/group

Change-Id: I9ee4093b028bda864fd554e95306df032a494038
Signed-off-by: Vishal Thapar <vishal.thapar@ericsson.com>
mdsalutil/mdsalutil-api/src/main/java/org/opendaylight/vpnservice/mdsalutil/MatchFieldType.java
mdsalutil/mdsalutil-impl/src/main/java/org/opendaylight/vpnservice/mdsalutil/internal/MDSALManager.java

index 2b4dac70543233e279180b05cb75ab22e9f23872..b889f1e5b2f9a0d248e655209f30b625c7c712a8 100644 (file)
@@ -163,8 +163,8 @@ public enum MatchFieldType {
         @Override
         public void setMatch(MatchBuilder matchBuilderInOut, MatchInfo matchInfo, Map<Class<?>, Object> mapMatchBuilder) {
 
-            StringBuffer nodeConnectorId = new StringBuffer().append("openflow:").append(matchInfo.getMatchValues()[0])
-            .append(':').append(matchInfo.getMatchValues()[1]);
+            StringBuffer nodeConnectorId = new StringBuffer().append("openflow:").append(matchInfo.getBigMatchValues()[0])
+            .append(':').append(matchInfo.getBigMatchValues()[1]);
             matchBuilderInOut.setInPort(new NodeConnectorId(nodeConnectorId.toString()));
         }
     },
index 8fe95ef15e8a89f2d07062089cd47df409bb7b07..fc9a5ff782b1544905175c0da2861be0ab5c114a 100644 (file)
@@ -124,7 +124,7 @@ public class MDSALManager implements AutoCloseable {
                 }
             });
         } catch (Exception e) {
-            s_logger.error("Could not install flow: {}, exception: {}", flowEntity, e);
+            s_logger.error("Could not install flow: {}", flowEntity, e);
         }
     }
 
@@ -165,7 +165,7 @@ public class MDSALManager implements AutoCloseable {
                 }
              });
            } catch (Exception e) {
-            s_logger.error("Could not install Group: {}, exception: {}", groupEntity, e);
+            s_logger.error("Could not install Group: {}", groupEntity, e);
             throw e;
         }
     }
@@ -205,7 +205,7 @@ public class MDSALManager implements AutoCloseable {
 
                 });
         } catch (Exception e) {
-            s_logger.error("Could not remove Flow: {}, exception: {}", flowEntity, e);
+            s_logger.error("Could not remove Flow: {}", flowEntity, e);
         }
     }
 
@@ -242,7 +242,7 @@ public class MDSALManager implements AutoCloseable {
                 }
             });
         } catch (Exception e) {
-            s_logger.error("Could not remove Group: {}, exception: {}", groupEntity, e);
+            s_logger.error("Could not remove Group: {}", groupEntity, e);
         }
     }