You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by ni...@apache.org on 2020/04/21 07:49:33 UTC

[ignite] branch master updated: IGNITE-12880 Adds PushMetricsExporterAdapter default export period value. (#7700)

This is an automated email from the ASF dual-hosted git repository.

nizhikov pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ignite.git


The following commit(s) were added to refs/heads/master by this push:
     new 4c7caef  IGNITE-12880 Adds PushMetricsExporterAdapter default export period value. (#7700)
4c7caef is described below

commit 4c7caef2cc21c1cee77b8ad5fb6a319b98abc1fe
Author: Mikhail Petrov <32...@users.noreply.github.com>
AuthorDate: Tue Apr 21 10:49:23 2020 +0300

    IGNITE-12880 Adds PushMetricsExporterAdapter default export period value. (#7700)
---
 .../internal/processors/metric/PushMetricsExporterAdapter.java       | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/metric/PushMetricsExporterAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/metric/PushMetricsExporterAdapter.java
index a8fd532..4755c3b 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/metric/PushMetricsExporterAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/metric/PushMetricsExporterAdapter.java
@@ -35,6 +35,9 @@ import static java.util.concurrent.TimeUnit.MILLISECONDS;
  * Base class for exporters that pushes metrics to the external system.
  */
 public abstract class PushMetricsExporterAdapter extends IgniteSpiAdapter implements MetricExporterSpi {
+    /** Default export period in milliseconds. */
+    public static final long DFLT_EXPORT_PERIOD = 60_000L;
+
     /** Metric registry. */
     protected ReadOnlyMetricManager mreg;
 
@@ -42,7 +45,7 @@ public abstract class PushMetricsExporterAdapter extends IgniteSpiAdapter implem
     protected  @Nullable Predicate<ReadOnlyMetricRegistry> filter;
 
     /** Export period. */
-    private long period;
+    private long period = DFLT_EXPORT_PERIOD;
 
     /** Push spi executor. */
     private ScheduledExecutorService execSvc;