Provide consistent hash code for enums and use it too 92/1292/2
authorGiovanni Meo <gmeo@cisco.com>
Thu, 19 Sep 2013 09:33:45 +0000 (11:33 +0200)
committerGerrit Code Review <gerrit@opendaylight.org>
Thu, 19 Sep 2013 14:37:58 +0000 (14:37 +0000)
commit92f103f5cc35c9807ae7717c9d8a25cda73b933c
treefa2b5150117387a61fd3a9f69e53f0c57a98ebd8
parent65497763171356ed5068e0040023f307dc7d4607
Provide consistent hash code for enums and use it too

- Java enums if used as key, works well in a single JVM, but across
JVM the hashcode generated by them is not guaranteed to be the same
and that breaks the calculation of a cluster wide consistent hash
code, needed by the clustering services. The fix is to provide a
consistent hashcode for the Enum and to use it in the dependent data
structures.

Change-Id: Iee80f262253a287e8bc8be4d5371d0bd407f0462
Signed-off-by: Giovanni Meo <gmeo@cisco.com>
opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/implementation/data/FlowEntryDistributionOrder.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/Action.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/ActionType.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/UpdateType.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/match/Match.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/match/MatchType.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/Status.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/StatusCode.java