Bug 4866: Add wait/retries for routed RPCs 75/34175/4
authorTom Pantelis <tpanteli@brocade.com>
Fri, 5 Feb 2016 07:42:54 +0000 (02:42 -0500)
committerTom Pantelis <tpanteli@brocade.com>
Tue, 23 Feb 2016 22:01:08 +0000 (17:01 -0500)
commit92ce52ab3df561a2a07bf56c7115123b0825449e
tree086ba4ded78e07f034590ea4ff76ec0c3caaa618
parent497d356874c8033e0d0f9fccfa7ed6695d6889fc
Bug 4866: Add wait/retries for routed RPCs

If a routed RPC is registered on one node it takes a little time for the
route to propagate via gossip to other nodes. If another node tries to
invoke the RPC prior to propagation it fails. To alleviate this timing
issue, I added wait/retries via a timer in the RpcRegistry for the
FindRouters message. As routes are updated via gossip, it retries the
FindRouters request. If the timer triggers, it sends back an empty list.
The timer period is 10 times the gossip tick interval (500ms * 10 = 5s).

Change-Id: Iaafcfb4c93cde44f62f6645c8b8684102ac0d0db
Signed-off-by: Tom Pantelis <tpanteli@brocade.com>
opendaylight/md-sal/sal-remoterpc-connector/src/main/java/org/opendaylight/controller/remote/rpc/RemoteRpcProviderConfig.java
opendaylight/md-sal/sal-remoterpc-connector/src/main/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistry.java
opendaylight/md-sal/sal-remoterpc-connector/src/main/java/org/opendaylight/controller/remote/rpc/registry/gossip/BucketStore.java
opendaylight/md-sal/sal-remoterpc-connector/src/test/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistryTest.java
opendaylight/md-sal/sal-remoterpc-connector/src/test/resources/application.conf
opendaylight/md-sal/sal-remoterpc-connector/src/test/resources/simplelogger.properties [new file with mode: 0644]