[
https://issues.apache.org/jira/browse/HBASE-18651?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16173300#comment-16173300
]
Mike Drob commented on HBASE-18651:
-----------------------------------
Patch looks good, only a few nits.
{code:title=ChaosMonkeyRunner}
+ Thread.sleep(10000); // 10 seconds
{code}
Use a variable for this so that interval can be configured. Fine for a
follow-on jira. Useful for setting a smaller interval so that we can let the
test run faster.
{code:title=Monkeys}
+ private ChaosMonkeyRunner monkeyRunner;
+ private Runnable runner;
+ private ExecutorService executor;
{code}
I think these can be final?
{code:title=Monkeys}
+ Preconditions.checkNotNull(conf, "Should specify a configuration");
+ this.conf = conf;
{code}
Can assign this.conf to the return of Preconditions.
IntegrationTestMonkeys::runMonkeys has a superfluous return statement.
Comment in IntegrationTestMonkeys::main does not match actual wait time.
> Let ChaosMonkeyRunner expose the chaos monkey runner it creates
> ---------------------------------------------------------------
>
> Key: HBASE-18651
> URL: https://issues.apache.org/jira/browse/HBASE-18651
> Project: HBase
> Issue Type: Improvement
> Reporter: Ted Yu
> Assignee: Reid Chan
> Attachments: HBASE-18651.master.001.patch,
> HBASE-18651.master.002.patch, HBASE-18651.master.003.patch,
> HBASE-18651.master.004.patch, HBASE-18651.master.005.patch
>
>
> Currently ChaosMonkeyRunner#main() instantiates ChaosMonkeyRunner without
> keeping track of the instance.
> This poses some challenge when ChaosMonkeyRunner is used programmatically
> because the caller cannot get hold of the runner.
> As [~mdrob] suggested, we should expose the chaos monkey runner.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)