zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nicktrav <...@git.apache.org>
Subject [GitHub] zookeeper issue #330: ZOOKEEPER-2471: ZK Java client should not count sleep ...
Date Fri, 18 Aug 2017 17:16:21 GMT
Github user nicktrav commented on the issue:

    Feels a little awkward to have a non-trivial change without any tests :/
    > I'm still going to be stuck depending on the behavior of that randomly-generated
sleep time, which is going to be inherently unreliable
    Thinking aloud here ... given your second commit updates to use the `Time` utility, could
you now inject that class, (or perhaps a faked implementation given the methods are static),
into `ClientCnxnSocket` and its subclasses? This would make it more amenable to testing. You'd
have more control over the times that are returned.
    You'd still need to plumb that through into `ClientCnxn`, but it looks like the constructor
takes a `ClientCnxnSocket`, which could work here?
    Maybe we can get that scaffolding wired up in another PR, get that merged in, and this
change could leverage that?

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.

View raw message