DomGarguilo opened a new pull request, #4740:
URL: https://github.com/apache/accumulo/pull/4740

   This PR simplifies the check for the Compactor that is used to determine 
when to change the idle process metric for the Compactor. The new code just 
returns true when no compaction is running and false when one is. It defers the 
time checking portion to the upstream logic in `AbstractServer`.
   
   The old method was to check how much time has passed since the last 
compaction was completed. There are at least two issues with this:
   1. There is logic that makes sure the amount of time since the last 
compaction happened is at least `idleReportingPeriodNanos`. This check also 
happens upstream when the `Supplier<boolean>` is read in `AbstractServer` so we 
are getting rid of that duplicate check in the new code.
   2. There is a check that the `System.nanoTime()` value of the last completed 
compaction is not negative. This is not a safe check to make since 
`System.nanoTime()` may provide a negative value. (This bug was identified 
[here](https://github.com/apache/accumulo/pull/4737#discussion_r1672754943))


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to