-
Bug
-
Resolution: Won't Do
-
Major
-
3.4
-
None
The Javadoc for JChannel.startFlush() says:
In case of flush collisions, a random sleep time backoff algorithm is employed and the flush is reattempted for numberOfAttempts. Therefore this method is guaranteed to return after timeout x numberOfAttempts milliseconds.
This does not appear to be true. I had two nodes call this method at the same time and immediately got an exception due to a flush collision. The salient part of the stack trace is:
Caused by: java.lang.Exception: Flush failed for EITSQL2-33698 at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:435) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:501) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.RSVP.up(RSVP.java:221) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.FRAG2.up(FRAG2.java:182) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.FlowControl.up(FlowControl.java:434) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.FlowControl.up(FlowControl.java:434) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:294) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.UNICAST3.removeAndDeliver(UNICAST3.java:796) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.UNICAST3.handleBatchReceived(UNICAST3.java:752) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.UNICAST3.up(UNICAST3.java:466) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:662) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.FD.up(FD.java:274) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.stack.Protocol.up(Protocol.java:409) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.TP.passBatchUp(TP.java:1422) [jgroups-3.4.0.Final.jar:3.4.0.Final] at org.jgroups.protocols.TP$BatchHandler.run(TP.java:1574) [jgroups-3.4.0.Final.jar:3.4.0.Final] ... 3 more
The Javadoc talks about "timeout" and "numberOfAttempts" as if they were method parameters, but they aren't. Were those part of an earlier version of JGroups? If they're still present, where are they? Will JGroups still retry a flush that failed due to a collision?