Class ThrottledBalancerProblemReporter
java.lang.Object
org.apache.accumulo.core.spi.balancer.util.ThrottledBalancerProblemReporter
Throttles logging of balancer problems by storing the last log time for each problem and limiting
reports to once per minute. The logger is generated internally from the supplied class in order
to adhere to the requirements for the SPI package (which prohibits having the Logger class in the
API).
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static interface
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Clears reported problems so that a problem report will be logged immediately the next timereportProblem(Problem)
is invoked.Create a new problem reporter to indicate there are no tablet servers available and balancing could not be performed.Create a new problem reporter to indicate that balancing could not be performed due to the existence of outstanding migrations.void
Reports a balance problem.
-
Constructor Details
-
ThrottledBalancerProblemReporter
-
-
Method Details
-
createNoTabletServersProblem
Create a new problem reporter to indicate there are no tablet servers available and balancing could not be performed. Balancers should only create a single instance of this problem, and reuse each time the problem is reported. -
createOutstandingMigrationsProblem
public ThrottledBalancerProblemReporter.OutstandingMigrationsProblem createOutstandingMigrationsProblem()Create a new problem reporter to indicate that balancing could not be performed due to the existence of outstanding migrations. Balancers should only create a single instance of this problem and update its migrations list before each report. -
reportProblem
Reports a balance problem. TheThrottledBalancerProblemReporter.Problem.report()
will only be called up to once a minute for each problem that is reported repeatedly. -
clearProblemReportTimes
public void clearProblemReportTimes()Clears reported problems so that a problem report will be logged immediately the next timereportProblem(Problem)
is invoked.
-