public abstract class PushMetricsExporterAdapter extends IgniteSpiAdapter implements MetricExporterSpi
| Modifier and Type | Field and Description |
|---|---|
static long |
DFLT_EXPORT_PERIOD
Default export period in milliseconds.
|
protected @Nullable Predicate<ReadOnlyMetricRegistry> |
filter
Metric filter.
|
protected ReadOnlyMetricManager |
mreg
Metric registry.
|
ignite, igniteInstanceName, log| Constructor and Description |
|---|
PushMetricsExporterAdapter() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
export()
Callback to do the export of metrics info.
|
long |
getPeriod() |
protected void |
onContextInitialized0(IgniteSpiContext spiCtx)
Method to be called in the end of onContextInitialized method.
|
void |
setExportFilter(Predicate<ReadOnlyMetricRegistry> filter)
Sets export filter.
|
void |
setMetricRegistry(ReadOnlyMetricManager mreg)
Sets metrics registry that SPI should export.
|
void |
setPeriod(long period)
Sets period in milliseconds after
export() method should be called. |
void |
spiStart(@Nullable String igniteInstanceName)
This method is called to start SPI.
|
void |
spiStop()
This method is called to stop SPI.
|
addTimeoutObject, assertParameter, checkConfigurationConsistency0, clientFailureDetectionTimeout, configInfo, createSpiAttributeName, failureDetectionTimeout, failureDetectionTimeoutEnabled, failureDetectionTimeoutEnabled, getConsistentAttributeNames, getExceptionRegistry, getLocalNode, getName, getNodeAttributes, getSpiContext, ignite, initFailureDetectionTimeout, injectables, injectResources, isNodeStopping, onBeforeStart, onClientDisconnected, onClientReconnected, onContextDestroyed, onContextDestroyed0, onContextInitialized, registerMBean, removeTimeoutObject, setName, started, startInfo, startStopwatch, stopInfo, unregisterMBeanclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetName, getNodeAttributes, onClientDisconnected, onClientReconnected, onContextDestroyed, onContextInitializedpublic static final long DFLT_EXPORT_PERIOD
protected ReadOnlyMetricManager mreg
@Nullable protected @Nullable Predicate<ReadOnlyMetricRegistry> filter
public void spiStart(@Nullable
@Nullable String igniteInstanceName)
throws IgniteSpiException
spiStart in interface IgniteSpiigniteInstanceName - Name of Ignite instance this SPI is being started for
(null for default Ignite instance).IgniteSpiException - Throws in case of any error during SPI start.public void spiStop()
throws IgniteSpiException
Note that this method can be called at any point including during recovery of failed start. It should make no assumptions on what state SPI will be in when this method is called.
spiStop in interface IgniteSpiIgniteSpiException - Thrown in case of any error during SPI stop.public abstract void export()
getPeriod() millisecond.public void setPeriod(long period)
export() method should be called.period - Period in milliseconds.public long getPeriod()
export() method should be called.public void setMetricRegistry(ReadOnlyMetricManager mreg)
IgniteSpi.spiStart(String).setMetricRegistry in interface MetricExporterSpimreg - Metric registry.public void setExportFilter(Predicate<ReadOnlyMetricRegistry> filter)
filter shouldn't be exported.setExportFilter in interface MetricExporterSpifilter - Filter.protected void onContextInitialized0(IgniteSpiContext spiCtx) throws IgniteSpiException
onContextInitialized0 in class IgniteSpiAdapterspiCtx - SPI context.IgniteSpiException - In case of errors.
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.10.0 Release Date : March 10 2021