public final class PollerConfigFactory extends PollerConfigManager
m_config
Constructor and Description |
---|
PollerConfigFactory(long currentVersion,
InputStream stream)
Constructor for PollerConfigFactory.
|
Modifier and Type | Method and Description |
---|---|
static PollerConfig |
getInstance()
Return the singleton instance of this factory.
|
static void |
init()
Load the config from the default config file and create the singleton
instance of this factory.
|
static void |
reload()
Reload the config from the default config file
|
protected void |
saveXml(String xml)
saveXml
|
static void |
setInstance(PollerConfig instance)
setInstance
|
static void |
setPollerConfigFile(File pollerConfigFile) |
void |
update()
update
|
addMonitor, addPackage, enumeratePackage, getAllPackageMatches, getConfiguration, getCriticalService, getDefaultCriticalPathIp, getDefaultCriticalPathRetries, getDefaultCriticalPathTimeout, getFirstLocalPackageMatch, getIpList, getNextOutageIdSql, getPackage, getPackages, getReadLock, getRRAList, getServiceInPackage, getServiceMonitor, getServiceMonitorLocators, getServiceMonitorNames, getServiceMonitorRegistry, getServiceMonitors, getServiceSelectorForPackage, getStep, getThreads, getWriteLock, isInterfaceInPackage, isNodeOutageProcessingEnabled, isPathOutageEnabled, isPolled, isPolled, isPolled, isPolledLocally, isPolledLocally, isServiceInPackageAndEnabled, isServiceMonitored, isServiceUnresponsiveEnabled, parameters, rebuildPackageIpListMap, save, setUpInternalData, shouldPollAllIfNoCriticalServiceDefined
public PollerConfigFactory(long currentVersion, InputStream stream)
Constructor for PollerConfigFactory.
currentVersion
- a long.stream
- a InputStream
object.public static void setPollerConfigFile(File pollerConfigFile) throws IOException
IOException
public static void init() throws IOException
IOException
- Thrown if the specified config file cannot be readIOException
- if any.public static void reload() throws IOException
IOException
- Thrown if the specified config file cannot be read/loadedIOException
- if any.public static PollerConfig getInstance()
IllegalStateException
- Thrown if the factory has not yet been initialized.public static void setInstance(PollerConfig instance)
setInstance
instance
- a PollerConfig
object.protected void saveXml(String xml) throws IOException
saveXml
saveXml
in class PollerConfigManager
xml
- a String
object.IOException
- if any.public void update() throws IOException
update
update
in interface PollerConfig
update
in class PollerConfigManager
IOException
- if any.Copyright © 2021. All rights reserved.