accumulo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adamjshook <>
Subject [GitHub] accumulo issue #254: [ACCUMULO-4506] Add a timeout to the replication task
Date Sun, 30 Apr 2017 14:57:24 GMT
Github user adamjshook commented on the issue:
    I've been reading up on `Executors#sameThreadExecutor`, and I don't think we can use this
here since it runs the task prior to getting any `Future`.  The timeout logic would not kick
in until the task is finished. 
     The task has to be run in a separate thread while the main thread idles to trigger the
    Additionally, I'm having a bit of trouble getting a unit test I am pleased with.  I've
made one that runs, but there is a race condition there where it'll either not run the task
at all or the task runs but it throws and logs a `Connection refused` error because there
is no server running to receive any work. You can take a look at the commit [here](
    Either way the test passes since the `Status` returned is the same, but it isn't a very
good test since the behavior isn't really defined.  I think we are a bit too high-level here
for a unit test.

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 or file a JIRA ticket
with INFRA.

View raw message