X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=openflowplugin-impl%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fopenflowplugin%2Fimpl%2Fregistry%2Fflow%2FFlowRegistryKeyFactory.java;fp=openflowplugin-impl%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fopenflowplugin%2Fimpl%2Fregistry%2Fflow%2FFlowRegistryKeyFactory.java;h=889e30a2c21f606852e154ce7ca14394973ee74b;hb=3c34de49abdc57fe13181e370e61e06a1e0ca658;hp=3919aa3c7553bc3d8cb1af2c7526ae92f029ac98;hpb=56d081b738b1844cca3f05209a778c484ae21914;p=openflowplugin.git diff --git a/openflowplugin-impl/src/main/java/org/opendaylight/openflowplugin/impl/registry/flow/FlowRegistryKeyFactory.java b/openflowplugin-impl/src/main/java/org/opendaylight/openflowplugin/impl/registry/flow/FlowRegistryKeyFactory.java index 3919aa3c75..889e30a2c2 100644 --- a/openflowplugin-impl/src/main/java/org/opendaylight/openflowplugin/impl/registry/flow/FlowRegistryKeyFactory.java +++ b/openflowplugin-impl/src/main/java/org/opendaylight/openflowplugin/impl/registry/flow/FlowRegistryKeyFactory.java @@ -13,6 +13,7 @@ import com.google.common.base.Preconditions; import java.math.BigInteger; import org.opendaylight.openflowplugin.api.OFConstants; import org.opendaylight.openflowplugin.api.openflow.registry.flow.FlowRegistryKey; +import org.opendaylight.openflowplugin.impl.util.MatchComparatorFactory; import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.Flow; import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.Match; import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.MatchBuilder; @@ -58,13 +59,15 @@ public class FlowRegistryKeyFactory { return getPriority() == that.getPriority() && getTableId() == that.getTableId() && - getMatch().equals(that.getMatch()); + getCookie().equals(that.getCookie()) && + MatchComparatorFactory.createMatch().areObjectsEqual(getMatch(), that.getMatch()); } @Override public int hashCode() { int result = tableId; result = 31 * result + priority; + result = 31 * result + cookie.hashCode(); result = 31 * result + match.hashCode(); return result; }