HBASE-23283 Provide clear and consistent logging about the period of enabled chores

Signed-off-by: Sean Busbey <busbey@apache.org>
This commit is contained in:
Mingliang Liu 2019-11-12 23:59:08 -08:00 committed by Sean Busbey
parent 4cc899d8e3
commit 73f3e1d4a4
1 changed files with 2 additions and 1 deletions

View File

@ -151,9 +151,10 @@ public class ChoreService implements ChoreServicer {
try { try {
if (chore.getPeriod() <= 0) { if (chore.getPeriod() <= 0) {
LOG.info("The period is {} seconds, {} is disabled", chore.getPeriod(), chore.getName()); LOG.info("Chore {} is disabled because its period is not positive.", chore);
return false; return false;
} }
LOG.info("Chore {} is enabled.", chore);
chore.setChoreServicer(this); chore.setChoreServicer(this);
ScheduledFuture<?> future = ScheduledFuture<?> future =
scheduler.scheduleAtFixedRate(chore, chore.getInitialDelay(), chore.getPeriod(), scheduler.scheduleAtFixedRate(chore, chore.getInitialDelay(), chore.getPeriod(),