[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-14 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 The new Tech Note: https://cwiki.apache.org/confluence/display/CURATOR/TN14 - I'd appreciate reviews. ---

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-11 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 Ok, will merge this now. Thanks @arrodrigues ! ---

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-11 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 Yeah, I agree @cammckenzie. Let's merge what we have here and I'll write up a Tech Note. ---

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-10 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 To Curator, don't they all look the same? Ultimately, Curator will just get a Disconnected event? Given that we can't tell the difference between them, I think that we just have to docu

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-10 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 > -If the connection between client and server is lost a disconnected event is received essentially immediately. > -If a heart beat is missed it takes 2/3 of the session timeout. Thinki

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-10 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 My issue is the difference in timing in these events: -If the connection between client and server is lost a disconnected event is received essentially immediately. -If a heart beat is mi

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-10 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 The ZK client code sends Disconnected when the Server disconnects or the server misses a heartbeat. So, that should be sufficient right? ---

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-09 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 I'm conflicted about the LOST injection stuff. I guess all we can do is err on the side of caution and leave it as is. That will cover what is presumably the most common case, where the connecti

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-08 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 I'd be -1 on more hacking into ZooKeeper. Trying to get all these timings to be accurate is a lost cause anyway - we can never simulate in the client the exact timing of the server. I suggest addin

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-08 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 That's a good point @arrodrigues I don't think we can tell the difference between Disconnected event from ZK due to loss of the underlying socket and a Disconected event due to no hear

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-06 Thread arrodrigues
Github user arrodrigues commented on the issue: https://github.com/apache/curator/pull/262 @cammckenzie It is on 2/3 of session timeout. I'd like to remember this will happen just in the scenario that I described in the issue description, in many other network issues the suspended

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-05 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 The changes look good to me, thanks @arrodrigues @Randgalt , I think the approach you're suggesting for setting up the default session timeout stuff looks OK. I thought that the suspend

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-05 Thread Randgalt
Github user Randgalt commented on the issue: https://github.com/apache/curator/pull/262 I'm thinking we change `StandardConnectionHandlingPolicy`. It should be 33 though right? By the time we get the Disconnected 2/3 of a session have elapsed. However, this could affect exis

[GitHub] curator issue #262: [CURATOR-460] Timed tolerance for connection suspended l...

2018-04-04 Thread cammckenzie
Github user cammckenzie commented on the issue: https://github.com/apache/curator/pull/262 Thanks for the updates, I think this looks good. I still think we need to look at the default behaviour of the ConnectionStateListener though. Currently, a LOST event will only be inject