You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-commits@jackrabbit.apache.org by am...@apache.org on 2019/03/19 15:25:36 UTC

svn commit: r1855842 - in /jackrabbit/oak/trunk/oak-run: ./ src/main/assembly/ src/main/java/org/apache/jackrabbit/oak/run/ src/test/java/org/apache/jackrabbit/oak/run/

Author: amitj
Date: Tue Mar 19 15:25:36 2019
New Revision: 1855842

URL: http://svn.apache.org/viewvc?rev=1855842&view=rev
Log:
OAK-8113: Add ability to push metrics to prometheus pushgateway from oak-run

- Added an option --export-metrics to enable export
- MetricsExporterFixture and FixtureProvider initialize metrics exporter based on type (currently only pushgateway).
- Additional io.prometheus.simpleclient* libraries made optional and not part of the jar and would need to be specified externally on the classpath

Added:
    jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java   (with props)
    jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java   (with props)
    jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java   (with props)
Modified:
    jackrabbit/oak/trunk/oak-run/README.md
    jackrabbit/oak/trunk/oak-run/pom.xml
    jackrabbit/oak/trunk/oak-run/src/main/assembly/oak-run.xml
    jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreCommand.java
    jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreOptions.java

Modified: jackrabbit/oak/trunk/oak-run/README.md
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/README.md?rev=1855842&r1=1855841&r2=1855842&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-run/README.md (original)
+++ jackrabbit/oak/trunk/oak-run/README.md Tue Mar 19 15:25:36 2019
@@ -517,6 +517,7 @@ Maintenance commands for the DataStore:
             [--max-age <seconds>] \
             [--verbose] \
             [<store_path>|<mongo_uri>]
+            [--metrics] [--export-metrics]
 
 The following operations are available:
     
@@ -539,9 +540,32 @@ The following options are available:
     <store_path|mongo_uri>  - Path to the tar segment store or the segment azure uri as specified in 
                                http://jackrabbit.apache.org/oak/docs/nodestore/segment/overview.html#remote-segment-stores
                                or if Mongo NodeStore then the mongo uri.
+    --metrics                - If metrics are to be captured.
+    --export-metrics         - Option to export the captured metrics. The format of the command is type;URL;key1=value1,key2=value2
+                              Currently only [Prometheus Pushgateway](https://github.com/prometheus/pushgateway) is supported
+                              e.g. --export-metrics "pushgateway;localhost:9091;key1=value1,key2=value2" 
 
 Note:
 
+Note: When using --export-metrics the following additional jars have to be downloaded to support Prometheus Pushgatway
+* [simpleclient_common-0.6.0.jar](http://central.maven.org/maven2/io/prometheus/simpleclient_common/0.6.0/simpleclient_common-0.6.0.jar) 
+* [simpleclient-0.6.0.jar](http://central.maven.org/maven2/io/prometheus/simpleclient/0.6.0/simpleclient-0.6.0.jar)
+* [simpleclient_pushgateway-0.6.0.jar](http://central.maven.org/maven2/io/prometheus/simpleclient_pushgateway/0.6.0/simpleclient_pushgateway-0.6.0.jar)
+* [simpleclient_dropwizard-0.6.0.jar](http://central.maven.org/maven2/io/prometheus/simpleclient_dropwizard/0.6.0/simpleclient_dropwizard-0.6.0.jar)
+
+The command to be executed when using this option is:
+
+    $ java -classpath oak-run-*.jar:simpleclient_common-0.6.0.jar:simpleclient-0.6.0.jar:simpleclient_dropwizard-0.6.0.jar:simpleclient_pushgateway-0.6.0.jar \
+        org.apache.jackrabbit.oak.run.Main \
+        datastore [--check-consistency|--collect-garbage [true]] \
+        [--s3ds <s3ds_config>|--fds <fds_config>|--azureds <s3ds_config>|fake-ds-path <ds_path>] \
+        [--out-dir <output_path>] \
+        [--work-dir <temporary_path>] \
+        [--max-age <seconds>] \
+        [--verbose] \
+        [<store_path>|<mongo_uri>]
+        [--metrics] [--export-metrics]
+    
 Data Store and node store configuration is mandatory.
 
 The config files should be formatted according to the OSGi configuration admin specification

Modified: jackrabbit/oak/trunk/oak-run/pom.xml
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/pom.xml?rev=1855842&r1=1855841&r2=1855842&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-run/pom.xml (original)
+++ jackrabbit/oak/trunk/oak-run/pom.xml Tue Mar 19 15:25:36 2019
@@ -372,7 +372,28 @@
       <groupId>org.jetbrains</groupId>
       <artifactId>annotations</artifactId>
     </dependency>
-    
+
+    <!-- Pushgateway -->
+    <dependency>
+      <groupId>io.prometheus</groupId>
+      <artifactId>simpleclient</artifactId>
+      <version>0.6.0</version>
+      <optional>true</optional>
+    </dependency>
+    <dependency>
+      <groupId>io.prometheus</groupId>
+      <artifactId>simpleclient_dropwizard</artifactId>
+      <version>0.6.0</version>
+      <optional>true</optional>
+    </dependency>
+    <!-- Pushgateway exposition-->
+    <dependency>
+      <groupId>io.prometheus</groupId>
+      <artifactId>simpleclient_pushgateway</artifactId>
+      <version>0.6.0</version>
+      <optional>true</optional>
+    </dependency>
+
     <!-- Test dependencies -->
     <dependency>
       <groupId>junit</groupId>

Modified: jackrabbit/oak/trunk/oak-run/src/main/assembly/oak-run.xml
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/main/assembly/oak-run.xml?rev=1855842&r1=1855841&r2=1855842&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/main/assembly/oak-run.xml (original)
+++ jackrabbit/oak/trunk/oak-run/src/main/assembly/oak-run.xml Tue Mar 19 15:25:36 2019
@@ -34,6 +34,7 @@
         <exclude>org.apache.tika:tika-core:*</exclude>
         <exclude>org.apache.tika:tika-parsers:*</exclude>
         <exclude>org.apache.jackrabbit:jackrabbit-aws-ext:*</exclude>
+        <exclude>io.prometheus:simpleclient*:*</exclude>
       </excludes>
       <useStrictFiltering>true</useStrictFiltering>
       <useProjectArtifact>true</useProjectArtifact>

Modified: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreCommand.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreCommand.java?rev=1855842&r1=1855841&r2=1855842&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreCommand.java (original)
+++ jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreCommand.java Tue Mar 19 15:25:36 2019
@@ -151,16 +151,23 @@ public class DataStoreCommand implements
 
     private void execute(NodeStoreFixture fixture,  DataStoreOptions dataStoreOpts, Options opts, Closer closer)
         throws Exception {
-        MarkSweepGarbageCollector collector = getCollector(fixture, dataStoreOpts, opts, closer);
-        if (dataStoreOpts.checkConsistency()) {
-            long missing = collector.checkConsistency();
-            log.warn("Found {} missing blobs", missing);
 
-            if (dataStoreOpts.isVerbose()) {
-                new VerboseIdLogger(opts).log();
+        try (Closer metricsCloser = Closer.create()) {
+            MetricsExporterFixture metricsExporterFixture =
+                MetricsExporterFixtureProvider.create(dataStoreOpts, fixture.getWhiteboard());
+            metricsCloser.register(metricsExporterFixture);
+
+            MarkSweepGarbageCollector collector = getCollector(fixture, dataStoreOpts, opts, closer);
+            if (dataStoreOpts.checkConsistency()) {
+                long missing = collector.checkConsistency();
+                log.warn("Found {} missing blobs", missing);
+
+                if (dataStoreOpts.isVerbose()) {
+                    new VerboseIdLogger(opts).log();
+                }
+            } else if (dataStoreOpts.collectGarbage()) {
+                collector.collectGarbage(dataStoreOpts.markOnly());
             }
-        } else if (dataStoreOpts.collectGarbage()) {
-            collector.collectGarbage(dataStoreOpts.markOnly());
         }
     }
 

Modified: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreOptions.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreOptions.java?rev=1855842&r1=1855841&r2=1855842&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreOptions.java (original)
+++ jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/DataStoreOptions.java Tue Mar 19 15:25:36 2019
@@ -47,6 +47,7 @@ public class DataStoreOptions implements
     private final OptionSpec<Long> blobGcMaxAgeInSecs;
     private final OptionSpec<Void> verbose;
     private final OptionSpec<Boolean> resetLoggingConfig;
+    private OptionSpec<String> exportMetrics;
 
     public DataStoreOptions(OptionParser parser) {
         collectGarbage = parser.accepts("collect-garbage",
@@ -73,6 +74,8 @@ public class DataStoreOptions implements
         resetLoggingConfig =
             parser.accepts("reset-log-config", "Reset logging config for testing purposes only").withOptionalArg()
                 .ofType(Boolean.class).defaultsTo(Boolean.TRUE);
+        exportMetrics = parser.accepts("export-metrics",
+            "type, URI to export the metrics and optional metadata all delimeted by semi-colon(;)").withRequiredArg();
 
         //Set of options which define action
         actionOpts = ImmutableSet.of(collectGarbage, consistencyCheck);
@@ -158,4 +161,12 @@ public class DataStoreOptions implements
         }
         return result;
     }
+
+    public boolean exportMetrics() {
+        return options.has(exportMetrics);
+    }
+
+    public String exportMetricsArgs() {
+        return exportMetrics.value(options);
+    }
 }

Added: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java?rev=1855842&view=auto
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java (added)
+++ jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java Tue Mar 19 15:25:36 2019
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.jackrabbit.oak.run;
+
+import java.io.Closeable;
+
+/**
+ * Fixture encapsulating metrics exporter instance of T
+ * @param <T>
+ */
+public interface MetricsExporterFixture<T> extends Closeable {
+
+    ExporterType getExporterType();
+
+    T getMetricsExporter();
+
+    enum ExporterType {
+        pushgateway("Prometheus Push Gateway");
+
+        private String type;
+
+        ExporterType(String type) {
+            this.type = type;
+        }
+    }
+}

Propchange: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixture.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java?rev=1855842&view=auto
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java (added)
+++ jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java Tue Mar 19 15:25:36 2019
@@ -0,0 +1,134 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.jackrabbit.oak.run;
+
+import java.io.IOException;
+import java.util.List;
+import java.util.Map;
+
+import com.codahale.metrics.MetricRegistry;
+import com.google.common.base.Splitter;
+import io.prometheus.client.CollectorRegistry;
+import io.prometheus.client.dropwizard.DropwizardExports;
+import io.prometheus.client.exporter.PushGateway;
+import org.apache.jackrabbit.oak.run.cli.NodeStoreFixtureProvider;
+import org.apache.jackrabbit.oak.spi.whiteboard.Whiteboard;
+import org.jetbrains.annotations.Nullable;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import static java.util.Collections.emptyMap;
+import static org.apache.jackrabbit.oak.spi.whiteboard.WhiteboardUtils.getService;
+
+/**
+ * Initialize different metrics exporter fixture based on parameters used.
+ */
+public class MetricsExporterFixtureProvider {
+    private static final Logger log = LoggerFactory.getLogger(NodeStoreFixtureProvider.class);
+
+    @Nullable
+    public static MetricsExporterFixture create(DataStoreOptions options, Whiteboard wb) throws Exception {
+        if (options.exportMetrics()) {
+            CollectorRegistry collectorRegistry = new CollectorRegistry();
+            wb.register(CollectorRegistry.class, collectorRegistry, emptyMap());
+
+            MetricRegistry metricRegistry = getService(wb, MetricRegistry.class);
+
+            ExportMetricsArgs
+                metricsArgs = new ExportMetricsArgs(options.exportMetricsArgs());
+            if (metricsArgs.getExporterType() == ExporterType.pushgateway) {
+                PushGateway pg = new PushGateway(metricsArgs.getPushUri());
+                new DropwizardExports(metricRegistry).register(collectorRegistry);
+
+                wb.register(PushGateway.class, pg, emptyMap());
+                return new MetricsExporterFixture<PushGateway>() {
+                    @Override public ExporterType getExporterType() {
+                        return ExporterType.pushgateway;
+                    }
+
+                    @Override public PushGateway getMetricsExporter() {
+                        return pg;
+                    }
+
+                    @Override public void close() throws IOException {
+                        pg.pushAdd(collectorRegistry, PushGateway.class.getName(), metricsArgs.getPushMap());
+                    }
+                };
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Metrics exporter arguments
+     *  1. Exporter Type
+     *  2. Exporter URI
+     *  3. Metadata map
+     *  e.g. pushgateway;uri;key1=value1,key2=value2
+     */
+    static class ExportMetricsArgs {
+        private final ExporterType exporterType;
+        private final String pushUri;
+        private final Map<String, String> pushMap;
+
+        ExportMetricsArgs(String args) {
+            List<String> split = Splitter.on(";").limit(3).omitEmptyStrings().trimResults().splitToList(args);
+            this.exporterType = ExporterType.valueOf(split.get(0));
+
+            if (split.size() < 2) {
+                throw new IllegalArgumentException("No URL defined");
+            }
+
+            this.pushUri = split.get(1);
+
+            if (split.size() > 2) {
+                this.pushMap = Splitter.on(",").omitEmptyStrings().trimResults().withKeyValueSeparator("=").split(split.get(2));
+            } else {
+                this.pushMap = emptyMap();
+            }
+            log.info("Map of properties pushed [{}]", pushMap);
+        }
+
+        public String getPushUri() {
+            return pushUri;
+        }
+
+        public Map<String, String> getPushMap() {
+            return pushMap;
+        }
+
+        public ExporterType getExporterType() {
+            return exporterType;
+        }
+    }
+
+
+    /**
+     * Exporter Type supported
+     */
+    public enum ExporterType {
+        pushgateway("Prometheus Push Gateway");
+
+        private String type;
+
+        ExporterType(String type) {
+            this.type = type;
+        }
+    }
+}

Propchange: jackrabbit/oak/trunk/oak-run/src/main/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java?rev=1855842&view=auto
==============================================================================
--- jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java (added)
+++ jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java Tue Mar 19 15:25:36 2019
@@ -0,0 +1,127 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.jackrabbit.oak.run;
+
+import java.util.Map;
+
+import com.google.common.collect.Maps;
+import io.prometheus.client.exporter.PushGateway;
+import joptsimple.OptionParser;
+import joptsimple.OptionSet;
+import org.apache.jackrabbit.oak.run.MetricsExporterFixtureProvider.ExportMetricsArgs;
+import org.apache.jackrabbit.oak.spi.whiteboard.DefaultWhiteboard;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.ExpectedException;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotEquals;
+import static org.junit.Assert.assertTrue;
+
+/**
+ * Tests for MetricsExporterFixtureProvider
+ */
+public class MetricsExporterFixtureProviderTest {
+
+    @Rule
+    public ExpectedException expectedEx = ExpectedException.none();
+
+    @Test
+    public void checkCorrectPushGatewayInit() throws Exception {
+        OptionParser parser = new OptionParser();
+        DataStoreOptions dataStoreOptions = new DataStoreOptions(parser);
+
+        OptionSet option = parser.parse("--export-metrics", "pushgateway;localhost:9091;key1=value1,key2=value2");
+        dataStoreOptions.configure(option);
+
+        MetricsExporterFixture metricsExporterFixture =
+            MetricsExporterFixtureProvider.create(dataStoreOptions, new DefaultWhiteboard());
+
+        assertEquals("pushgateway", metricsExporterFixture.getExporterType().name());
+        Object metricsExporter = metricsExporterFixture.getMetricsExporter();
+        assertTrue(metricsExporter instanceof PushGateway);
+    }
+
+    @Test
+    public void testMetricArgs() throws Exception {
+        String option = "pushgateway;localhost:9091;key1=value1,key2=value2";
+        Map<String, String> expectedMap = Maps.newHashMap();
+        expectedMap.put("key1", "value1");
+        expectedMap.put("key2", "value2");
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+
+        assertEquals("pushgateway", metricsArgs.getExporterType().name());
+        assertEquals("localhost:9091", metricsArgs.getPushUri());
+        assertEquals(expectedMap, metricsArgs.getPushMap());
+    }
+
+    @Test
+    public void testMetricArgsNoType() throws Exception {
+        expectedEx.expect(java.lang.IllegalArgumentException.class);
+
+        String option = "localhost:9091;key1=value1,key2=value2";
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+    }
+
+    @Test
+    public void testMetricArgsWrongType() throws Exception {
+        expectedEx.expect(java.lang.IllegalArgumentException.class);
+
+        String option = "wrongtype:localhost:9091;key1=value1,key2=value2";
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+    }
+
+    @Test
+    public void testMetricArgsNoProps() throws Exception {
+        String option = "pushgateway;localhost:9091";
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+
+        assertEquals("pushgateway", metricsArgs.getExporterType().name());
+        assertEquals("localhost:9091", metricsArgs.getPushUri());
+        assertEquals(Maps.newHashMap(), metricsArgs.getPushMap());
+    }
+
+    @Test
+    public void testMetricArgsNoUrlNoMap() throws Exception {
+        expectedEx.expect(java.lang.IllegalArgumentException.class);
+
+        String option = "pushgateway";
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+    }
+
+    @Test
+    public void testMetricArgsNoUrl() throws Exception {
+        expectedEx.expect(java.lang.IllegalArgumentException.class);
+
+        String option = "pushgateway:key1=value1,key2=value2";
+        Map<String, String> expectedMap = Maps.newHashMap();
+        expectedMap.put("key1", "value1");
+        expectedMap.put("key2", "value2");
+
+        ExportMetricsArgs metricsArgs = new ExportMetricsArgs(option);
+        assertEquals("pushgateway", metricsArgs.getExporterType().name());
+        assertNotEquals(expectedMap, metricsArgs.getPushMap());
+        assertNotEquals("localhost:9091", metricsArgs.getPushUri());
+    }
+}

Propchange: jackrabbit/oak/trunk/oak-run/src/test/java/org/apache/jackrabbit/oak/run/MetricsExporterFixtureProviderTest.java
------------------------------------------------------------------------------
    svn:eol-style = native