You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@fluo.apache.org by mikewalch <gi...@git.apache.org> on 2016/09/14 15:39:29 UTC

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

GitHub user mikewalch opened a pull request:

    https://github.com/apache/incubator-fluo/pull/767

    Fixes #534 - Enable reporting application metrics

    * Fluo users can report application metrics from observers
    * Updated Grafan documentation to include new InfluxDB configuration
      for handling application metrics.
    * Added basic test to ObserverConfigIT to test creating reporter in an observer

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/mikewalch/incubator-fluo app-metrics

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-fluo/pull/767.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #767
    
----
commit fab252bdf49b28b8ba82146f23b6be1b01db6ce6
Author: Mike Walch <mw...@apache.org>
Date:   2016-09-13T17:22:59Z

    Fixes #534 - Enable reporting application metrics
    
    * Fluo users can report application metrics from observers
    * Updated Grafan documentation to include new InfluxDB configuration
      for handling application metrics.
    * Added basic test to ObserverConfigIT to test creating reporter in an observer

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79247279
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    --- End diff --
    
    fixed in 7e0c08fec69e


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79240922
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    --- End diff --
    
    s/helps users/help users/


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79247441
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    +monitor its performance. Users can also write code to report 'application' metrics from their
    +applications. Both 'application' and 'default' metrics share the same reporter configured by 
    +[fluo.properties] and are described in detail below.
     
    -1.  [Grafana/InfluxDB][3] - Fluo has [documentation][3] for sending metrics to InfluxDB and viewing
    -    them in Grafana.
    +## Configuring reporters
     
    -2.  JMX - Fluo can be configured to reports metrics via JMX which can be viewed in jconsole or
    -    jvisualvm.
    +Fluo metrics are not published by default. To publish metrics, configure a reporter in the 'metrics'
    +section of [fluo.properties]. There are several different reporter types (i.e Console, CSV, 
    +Graphite, JMX, SLF4J) that are implemented using [Dropwizard]. The choice of which reporter to use
    +depends on the visualization tool used. If you are not currently using a visualization tool, there
    +is [documentation][grafana] for reporting Fluo metrics to Grafana/InfluxDB.
     
    -3.  CSV - Fluo can be configured to output metrics as CSV to a specified directory.
    +## Metrics names
     
    -## Configuring Reporters
    +When Fluo metrics are reported, they are published using a naming scheme that encodes additional
    +information.
     
    -In order to configure metrics reporters, look at the metrics section in an applications
    -`fluo.properties` file. This sections has a lot of commented out options for configuring reporters.
    +Default metrics start with `fluo.class` or `fluo.system` and have following naming schemes:
     
    -    fluo.metrics.reporter.console.enable=false
    -    fluo.metrics.reporter.console.frequency=30
    +        fluo.class.APPLICATION.REPORTER_ID.METRIC.CLASS
    --- End diff --
    
    i tried adding greater/less than but i think it makes it harder to read.  i made it more explicit that all caps are variables in 7e0c08fec69e


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79241155
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    +monitor its performance. Users can also write code to report 'application' metrics from their
    --- End diff --
    
    I would write :
    
    Users can also write code to report application specific metrics.



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79001397
  
    --- Diff: modules/api/src/main/java/org/apache/fluo/api/observer/MetricsReporter.java ---
    @@ -0,0 +1,60 @@
    +/*
    + * 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.fluo.api.observer;
    --- End diff --
    
    Fixed in 395204c9ef


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79238896
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    +monitor its performance. Users can also write code to report 'application' metrics from their
    +applications. Both 'application' and 'default' metrics share the same reporter configured by 
    +[fluo.properties] and are described in detail below.
     
    -1.  [Grafana/InfluxDB][3] - Fluo has [documentation][3] for sending metrics to InfluxDB and viewing
    -    them in Grafana.
    +## Configuring reporters
     
    -2.  JMX - Fluo can be configured to reports metrics via JMX which can be viewed in jconsole or
    -    jvisualvm.
    +Fluo metrics are not published by default. To publish metrics, configure a reporter in the 'metrics'
    +section of [fluo.properties]. There are several different reporter types (i.e Console, CSV, 
    +Graphite, JMX, SLF4J) that are implemented using [Dropwizard]. The choice of which reporter to use
    +depends on the visualization tool used. If you are not currently using a visualization tool, there
    +is [documentation][grafana] for reporting Fluo metrics to Grafana/InfluxDB.
     
    -3.  CSV - Fluo can be configured to output metrics as CSV to a specified directory.
    +## Metrics names
     
    -## Configuring Reporters
    +When Fluo metrics are reported, they are published using a naming scheme that encodes additional
    +information.
     
    -In order to configure metrics reporters, look at the metrics section in an applications
    -`fluo.properties` file. This sections has a lot of commented out options for configuring reporters.
    +Default metrics start with `fluo.class` or `fluo.system` and have following naming schemes:
     
    -    fluo.metrics.reporter.console.enable=false
    -    fluo.metrics.reporter.console.frequency=30
    +        fluo.class.APPLICATION.REPORTER_ID.METRIC.CLASS
    +        fluo.system.APPLICATION.REPORTER_ID.METRIC
    +        
    +Application metrics start with `fluo.app` and have following scheme:
    +        
    +        fluo.app.REPORTER_ID.METRIC
    + 
    +The additional information encoded in the schemes above are described below:
     
    -The frequency is in seconds for all reporters.
    +1. `APPLICATION` - Fluo application name
    +2. `REPORTER_ID` - Unique ID of the Fluo oracle, worker, or client that is reporting the metric. 
    +    When running in yarn, this ID is of the format `worker-<instance id>` or `oracle-<instance id>`.
    +    When not running from yarn, this ID consists of a hostname and a base36 long that is unique 
    +    across all fluo processes.
    +3. `METRIC` - Name of the metric. For 'default' metrics, this is set by Fluo. For 'application'
    +    metrics, this is set by user. Name should be unique and avoid using period '.' in name.
    +4. `CLASS` - Name of Fluo observer or loader class that produced metric. This allows things like
    +    transaction collisions to be tracked per class.
    +    
    +## Application metrics
     
    -## Metrics reported by Fluo
    +Application metrics are implemented by retrieving a [MetricsReporter] from an [Observer], [Loader],
    +or [FluoClient].  These metrics are named using the format `fluo.app.REPORTER_ID.METRIC`.
     
    -All metrics reported by Fluo have the prefix `fluo.<APP>.<PID>.` which is denoted by `<prefix>` in
    -the table below. In the prefix, `<APP>` represents the Fluo application name and `<PID>` is the
    -process ID of the Fluo oracle or worker that is reporting the metric. When running in yarn, this id
    -is of the format `worker-<instance id>` or `oracle-<instance id>`. When not running from yarn, this
    -id consist of a hostname and a base36 long that is unique across all fluo processes.
    +## Default metrics
     
    -Some of the metrics reported have the class name as the suffix. This classname is the observer or
    -load task that executed the transactions. This should allow things like transaction collisions to
    -be tracked per class. In the table below this is denoted with `<cn>`.
    +Default metrics report for a particular Observer/Loader class or system-wide.
     
    -|Metric                                 | Type           | Description                         |
    -|---------------------------------------|----------------|-------------------------------------|
    -|\<prefix\>.tx.lock_wait_time.\<cn\>    | [Timer][T]     | *WHEN:* After each transaction. *COND:* &gt; 0 *WHAT:* Time transaction spent waiting on locks held by other transactions.  |
    -|\<prefix\>.tx.execution_time.\<cn\>    | [Timer][T]     | *WHEN:* After each transaction. *WHAT:* Time transaction took to execute. Updated for failed and successful transactions. This does not include commit time, only the time from start until commit is called. |
    -|\<prefix\>.tx.with_collision.\<cn\>    | [Meter][M]     | *WHEN:* After each transaction. *WHAT:* Rate of transactions with collisions. |
    -|\<prefix\>.tx.collisions.\<cn\>        | [Meter][M]     | *WHEN:* After each transaction. *WHAT:* Rate of collisions. |
    -|\<prefix\>.tx.entries_set.\<cn\>       | [Meter][H]     | *WHEN:* After each transaction. *WHAT:* Rate of row/columns set by transaction |
    -|\<prefix\>.tx.entries_read.\<cn\>      | [Meter][H]     | *WHEN:* After each transaction. *WHAT:* Rate of row/columns read by transaction that existed. There is currently no count of all reads (including non-existent data) |
    -|\<prefix\>.tx.locks_timedout.\<cn\>    | [Meter][M]     | *WHEN:* After each transaction. *WHAT:* Rate of timedout locks rolled back by transaction. These are locks that are held for very long periods by another transaction that appears to be alive based on zookeeper. |
    -|\<prefix\>.tx.locks_dead.\<cn\>        | [Meter][M]     | *WHEN:* After each transaction. *WHAT:* Rate of dead locks rolled by a transaction. These are locks held by a process that appears to be dead according to zookeeper. |
    -|\<prefix\>.tx.status_\<status\>.\<cn\> | [Meter][M]     | *WHEN:* After each transaction. *WHAT:* Rate of different ways a transaction can terminate |
    -|\<prefix\>.oracle.response_time        | [Timer][T]     | *WHEN:* For each request for stamps to the server. *WHAT:* Time RPC call to oracle took |
    -|\<prefix\>.oracle.client_stamps        | [Histogram][H] | *WHEN:* For each request for stamps to the server. *WHAT:* The number of stamps requested. |
    -|\<prefix\>.oracle.server_stamps        | [Histogram][H] | *WHEN:* For each request for stamps from a client. *WHAT:* The number of stamps requested. |
    -|\<prefix\>.worker.notifications_queued | [Gauge][G]     | *WHAT:* The current number of notifications queued for processing. |
    -|\<prefix\>.transactor.committing       | [Gauge][G]     | *WHAT:* The current number of transactions that are working their way through the commit steps. |
    +Below are metrics that are reported from each Observer/Loader class that is configured in a Fluo
    +application. These metrics are reported after each transaction and named using the format 
    +`fluo.class.APPLICATION.REPORTER_ID.METRIC.CLASS`.
    --- End diff --
    
    Its not clear how the things below fit into the pattern.  Maybe if it said `Below are metric ids` it would make it a little more clear.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79409232
  
    --- Diff: modules/core/src/main/java/org/apache/fluo/core/metrics/MetricsReporterImpl.java ---
    @@ -0,0 +1,65 @@
    +/*
    + * 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.fluo.core.metrics;
    +
    +import com.codahale.metrics.MetricRegistry;
    +import org.apache.fluo.api.config.FluoConfiguration;
    +import org.apache.fluo.api.metrics.Counter;
    +import org.apache.fluo.api.metrics.Histogram;
    +import org.apache.fluo.api.metrics.Meter;
    +import org.apache.fluo.api.metrics.MetricsReporter;
    +import org.apache.fluo.api.metrics.Timer;
    +import org.apache.fluo.core.metrics.types.CounterImpl;
    +import org.apache.fluo.core.metrics.types.HistogramImpl;
    +import org.apache.fluo.core.metrics.types.MeterImpl;
    +import org.apache.fluo.core.metrics.types.TimerImpl;
    +
    +/**
    + * Implementation of {@link MetricsReporter} that reports application metrics using Fluo metrics
    + */
    +public class MetricsReporterImpl implements MetricsReporter {
    +
    +  private final FluoConfiguration config;
    +  private final MetricRegistry registry;
    +  private final String prefix;
    +
    +  public MetricsReporterImpl(FluoConfiguration config, MetricRegistry registry,
    +      String metricsReporterID) {
    +    this.config = config;
    +    this.registry = registry;
    +    this.prefix = MetricNames.APPLICATION_PREFIX + "." + metricsReporterID + ".";
    +  }
    +
    +  @Override
    +  public Counter counter(String metricName) {
    --- End diff --
    
    These calls should probably have a not null check and after that check the string does not contain `.`.  I Think in this case if the metricName were null it would successfully concatenate with the string.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79238042
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    +monitor its performance. Users can also write code to report 'application' metrics from their
    +applications. Both 'application' and 'default' metrics share the same reporter configured by 
    +[fluo.properties] and are described in detail below.
     
    -1.  [Grafana/InfluxDB][3] - Fluo has [documentation][3] for sending metrics to InfluxDB and viewing
    -    them in Grafana.
    +## Configuring reporters
     
    -2.  JMX - Fluo can be configured to reports metrics via JMX which can be viewed in jconsole or
    -    jvisualvm.
    +Fluo metrics are not published by default. To publish metrics, configure a reporter in the 'metrics'
    +section of [fluo.properties]. There are several different reporter types (i.e Console, CSV, 
    +Graphite, JMX, SLF4J) that are implemented using [Dropwizard]. The choice of which reporter to use
    +depends on the visualization tool used. If you are not currently using a visualization tool, there
    +is [documentation][grafana] for reporting Fluo metrics to Grafana/InfluxDB.
     
    -3.  CSV - Fluo can be configured to output metrics as CSV to a specified directory.
    +## Metrics names
     
    -## Configuring Reporters
    +When Fluo metrics are reported, they are published using a naming scheme that encodes additional
    +information.
     
    -In order to configure metrics reporters, look at the metrics section in an applications
    -`fluo.properties` file. This sections has a lot of commented out options for configuring reporters.
    +Default metrics start with `fluo.class` or `fluo.system` and have following naming schemes:
     
    -    fluo.metrics.reporter.console.enable=false
    -    fluo.metrics.reporter.console.frequency=30
    +        fluo.class.APPLICATION.REPORTER_ID.METRIC.CLASS
    --- End diff --
    
    To be consistent w/ rest of document seems like this should be
    
    ```
    fluo.class.<APPLICATION>.<REPORTER_ID>.<METRIC>.<CLASS>
    ```
    
    Or could remove use of less than and greater than in the rest of the document.  Should probably explain the convention used for things that vary not matter how its done. 
    
    Could use a convention that things in *italics* vary like: fluo.class.*application*.*reporter_id*.*metrics*.*class* . Maybe thats too subtle.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79247465
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    +monitor its performance. Users can also write code to report 'application' metrics from their
    --- End diff --
    
    fixed in 7e0c08fec69e


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo issue #767: Fixes #534 - Enable reporting application metrics

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on the issue:

    https://github.com/apache/incubator-fluo/pull/767
  
    Seems like something should be added to docs/metrics.md to explain this new feature at a conceptual level.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79001664
  
    --- Diff: modules/api/src/main/java/org/apache/fluo/api/observer/MetricsReporter.java ---
    @@ -0,0 +1,60 @@
    +/*
    + * 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.fluo.api.observer;
    +
    +import java.util.concurrent.TimeUnit;
    +
    +/**
    + * Reports application metrics using Fluo metrics reporters configured by 'fluo.metrics.reporter.*'
    + * properties. Use unique names when naming metrics.
    + *
    + * @since 1.0.0
    + */
    +public interface MetricsReporter {
    +
    +  /**
    +   * Updates counter with change
    +   *
    +   * @param name Counter name
    +   * @param change Positive or negative number to increment/decrement number
    +   */
    +  void updateCounter(String name, long change);
    --- End diff --
    
    Yes, metrics need unique names.  There was some documentation of this but added more in 395204c9ef


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch closed the pull request at:

    https://github.com/apache/incubator-fluo/pull/767


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79001832
  
    --- Diff: modules/api/src/main/java/org/apache/fluo/api/observer/MetricsReporter.java ---
    @@ -0,0 +1,60 @@
    +/*
    + * 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.fluo.api.observer;
    +
    +import java.util.concurrent.TimeUnit;
    +
    +/**
    + * Reports application metrics using Fluo metrics reporters configured by 'fluo.metrics.reporter.*'
    + * properties. Use unique names when naming metrics.
    + *
    + * @since 1.0.0
    + */
    +public interface MetricsReporter {
    +
    +  /**
    +   * Updates counter with change
    +   *
    +   * @param name Counter name
    +   * @param change Positive or negative number to increment/decrement number
    +   */
    +  void updateCounter(String name, long change);
    +
    +  /**
    +   * Update meter by marking that a number of events has occurred
    --- End diff --
    
    Added links to dropwizard metric types in 395204c9ef


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79001442
  
    --- Diff: modules/api/src/main/java/org/apache/fluo/api/observer/MetricsReporter.java ---
    @@ -0,0 +1,60 @@
    +/*
    + * 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.fluo.api.observer;
    +
    +import java.util.concurrent.TimeUnit;
    +
    +/**
    + * Reports application metrics using Fluo metrics reporters configured by 'fluo.metrics.reporter.*'
    + * properties. Use unique names when naming metrics.
    + *
    + * @since 1.0.0
    + */
    +public interface MetricsReporter {
    --- End diff --
    
    Fixed in 395204c9ef


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo issue #767: Fixes #534 - Enable reporting application metrics

Posted by mikewalch <gi...@git.apache.org>.
Github user mikewalch commented on the issue:

    https://github.com/apache/incubator-fluo/pull/767
  
    This PR doesn't have to be included in 1.0.0 but if can get in that would be great.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-fluo pull request #767: Fixes #534 - Enable reporting application ...

Posted by keith-turner <gi...@git.apache.org>.
Github user keith-turner commented on a diff in the pull request:

    https://github.com/apache/incubator-fluo/pull/767#discussion_r79240755
  
    --- Diff: docs/metrics.md ---
    @@ -1,69 +1,112 @@
     # Fluo Metrics
     
    -Fluo core is instrumented using [dropwizard metrics][1]. This allows fluo users to easily gather
    -information about Fluo by configuring different reporters. While dropwizard can be configured to
    -report Fluo metrics to many different tools, below are some tools that have been used with Fluo.
    +A Fluo application can be configured (in [fluo.properties]) to report metrics. When metrics are 
    +configured, Fluo will report will some 'default' metrics about an application that helps users 
    --- End diff --
    
    will report will some


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---