public class ContentPackLoaderPeriodical extends Periodical
| Constructor and Description |
|---|
ContentPackLoaderPeriodical(com.fasterxml.jackson.databind.ObjectMapper objectMapper,
ContentPackService contentPackService,
ContentPackPersistenceService contentPackPersistenceService,
ContentPackInstallationPersistenceService contentPackInstallationPersistenceService,
Configuration configuration,
boolean contentPacksLoaderEnabled,
Path contentPacksDir,
Set<String> contentPacksAutoInstall) |
| Modifier and Type | Method and Description |
|---|---|
void |
doRun() |
int |
getInitialDelaySeconds() |
protected org.slf4j.Logger |
getLogger() |
int |
getPeriodSeconds() |
boolean |
isDaemon()
Should this periodical be run as a daemon thread?
|
boolean |
leaderOnly()
Determines if this periodical should run only on the leader node.
|
boolean |
runsForever()
Defines if this thread should be called periodically or only once
on startup.
|
boolean |
startOnThisNode()
Start on this node? Useful to decide if to start the periodical based on local configuration.
|
boolean |
stopOnGracefulShutdown()
Should this thread be stopped when a graceful shutdown is in progress?
This means that stop() is called and that is no longer triggered periodically.
|
getParallelism, initialize, masterOnly, run@Inject
public ContentPackLoaderPeriodical(com.fasterxml.jackson.databind.ObjectMapper objectMapper,
ContentPackService contentPackService,
ContentPackPersistenceService contentPackPersistenceService,
ContentPackInstallationPersistenceService contentPackInstallationPersistenceService,
Configuration configuration,
@Named(value="content_packs_loader_enabled")
boolean contentPacksLoaderEnabled,
@Named(value="content_packs_dir")
Path contentPacksDir,
@Named(value="content_packs_auto_install")
Set<String> contentPacksAutoInstall)
public boolean runsForever()
PeriodicalrunsForever in class Periodicalpublic boolean stopOnGracefulShutdown()
PeriodicalstopOnGracefulShutdown in class Periodicalpublic boolean leaderOnly()
PeriodicalleaderOnly in class Periodicalfalse (default) if this periodical may run on every node. true if it may run only on the
leader nodepublic boolean startOnThisNode()
PeriodicalstartOnThisNode in class Periodicalpublic boolean isDaemon()
PeriodicalisDaemon 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–2022 Graylog, Inc.. All rights reserved.