public class ThrottleStateUpdaterThread extends Periodical
It only includes the necessary information to make a decision about whether to throttle parts of the system, but does not send "throttle" commands. This allows for a flexible approach in picking a throttling strategy.
The implementation expects to be called once per second to have a rough estimate about the events per second, over the last second.
| Constructor and Description |
|---|
ThrottleStateUpdaterThread(Journal journal,
ProcessBuffer processBuffer,
com.google.common.eventbus.EventBus eventBus,
NotificationService notificationService,
ServerStatus serverStatus,
com.github.joschi.jadconfig.util.Size retentionSize) |
| Modifier and Type | Method and Description |
|---|---|
void |
doRun() |
int |
getInitialDelaySeconds() |
protected org.slf4j.Logger |
getLogger() |
int |
getPeriodSeconds() |
boolean |
isDaemon() |
boolean |
masterOnly() |
boolean |
runsForever() |
boolean |
startOnThisNode() |
boolean |
stopOnGracefulShutdown() |
getParallelism, initialize, run@Inject public ThrottleStateUpdaterThread(Journal journal, ProcessBuffer processBuffer, com.google.common.eventbus.EventBus eventBus, NotificationService notificationService, ServerStatus serverStatus, @Named(value="message_journal_max_size") com.github.joschi.jadconfig.util.Size retentionSize)
public boolean runsForever()
runsForever in class Periodicalpublic boolean stopOnGracefulShutdown()
stopOnGracefulShutdown in class Periodicalpublic boolean masterOnly()
masterOnly in class Periodicalpublic boolean startOnThisNode()
startOnThisNode in class Periodicalpublic boolean isDaemon()
isDaemon in class Periodicalpublic int getInitialDelaySeconds()
getInitialDelaySeconds in class Periodicalpublic int getPeriodSeconds()
getPeriodSeconds in class Periodicalprotected org.slf4j.Logger getLogger()
getLogger in class Periodicalpublic void doRun()
doRun in class PeriodicalCopyright © 2012-2015 Graylog, Inc.. All Rights Reserved.