Skip to content

Commit

Permalink
Fix JavaDoc warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
fstab committed Feb 5, 2022
1 parent c70a2e2 commit c205ef3
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 13 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ when using this approach ensure the value you are reporting accounts for concurr

### Summary

Summaries and Histograms can both be used to monitor latencies (or other things like request sizes).
Summaries and Histograms can both be used to monitor distributions, like latencies or request sizes.

An overview of when to use Summaries and when to use Histograms can be found on [https://prometheus.io/docs/practices/histograms](https://prometheus.io/docs/practices/histograms).

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* <p>
* This class handles common initialization and label logic for the standard metrics.
* You should never subclass this class.
* <p>
*
* <h2>Initialization</h2>
* After calling build() on a subclass, {@link Builder#name(String) name},
* {@link SimpleCollector.Builder#help(String) help},
Expand Down
16 changes: 8 additions & 8 deletions simpleclient/src/main/java/io/prometheus/client/Summary.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
import java.util.concurrent.TimeUnit;

/**
* {@link Summary} metrics and {@link Histogram} metrics can both be used to monitor latencies (or other things like request sizes).
* {@link Summary} metrics and {@link Histogram} metrics can both be used to monitor distributions like latencies or request sizes.
* <p>
* An overview of when to use Summaries and when to use Histograms can be found on <a href="https://prometheus.io/docs/practices/histograms">https://prometheus.io/docs/practices/histograms</a>.
* <p>
Expand Down Expand Up @@ -47,12 +47,12 @@
* The {@link Summary} class provides different utility methods for observing values, like {@link #observe(double)},
* {@link #startTimer()} and {@link Timer#observeDuration()}, {@link #time(Callable)}, etc.
* <p>
* By default, {@link Summary} metrics provide the <tt>count</tt> and the <tt>sum</tt>. For example, if you measure
* latencies of a REST service, the <tt>count</tt> will tell you how often the REST service was called,
* and the <tt>sum</tt> will tell you the total aggregated response time.
* You can calculate the average response time using a Prometheus query dividing <tt>sum / count</tt>.
* By default, {@link Summary} metrics provide the {@code count} and the {@code sum}. For example, if you measure
* latencies of a REST service, the {@code count} will tell you how often the REST service was called,
* and the {@code sum} will tell you the total aggregated response time.
* You can calculate the average response time using a Prometheus query dividing {@code sum / count}.
* <p>
* In addition to <tt>count</tt> and <tt>sum</tt>, you can configure a Summary to provide quantiles:
* In addition to {@code count} and {@code sum}, you can configure a Summary to provide quantiles:
*
* <pre>
* Summary requestLatency = Summary.build()
Expand All @@ -76,9 +76,9 @@
*
* <ul>
* <li>You can set an allowed error of 0, but then the {@link Summary} will keep all observations in memory.</li>
* <li>You can track the minimum value with <tt>.quantile(0.0, 0.0)</tt>.
* <li>You can track the minimum value with {@code .quantile(0.0, 0.0)}.
* This special case will not use additional memory even though the allowed error is 0.</li>
* <li>You can track the maximum value with <tt>.quantile(1.0, 0.0)</tt>.
* <li>You can track the maximum value with {@code .quantile(1.0, 0.0)}.
* This special case will not use additional memory even though the allowed error is 0.</li>
* </ul>
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@

/**
* Collect metrics from jetty's org.eclipse.jetty.server.handler.StatisticsHandler.
* <p>
* <pre>{@code
* <pre>
* Server server = new Server(8080);
*
* ServletContextHandler context = new ServletContextHandler();
Expand All @@ -29,7 +28,7 @@
* server.setHandler(handlers);
*
* server.start();
* }</pre>
* </pre>
*/
public class JettyStatisticsCollector extends Collector {
private final StatisticsHandler statisticsHandler;
Expand Down

0 comments on commit c205ef3

Please sign in to comment.