Skip to content

Commit af86030

Browse files
authored
Adopt review comments on doc updates (helidon-io#4627)
1 parent f3044bf commit af86030

8 files changed

Lines changed: 23 additions & 12 deletions

File tree

docs/includes/attributes.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ endif::[]
7676
:version-lib-oracle-ucp: {version-lib-oracle-jdbc}
7777
:version-plugin-jib: 0.10.1
7878
:version-plugin-jandex: 1.0.6
79+
:version-lib-micrometer: 1.6.6
7980
8081
:jdk-version: 17
8182
@@ -258,5 +259,7 @@ endif::[]
258259
259260
:micrometer-url: https://micrometer.io
260261
:micrometer-api-url: https://micrometer.io/docs/concepts
262+
:micrometer-javadoc-base-url: https://javadoc.io/doc/io.micrometer
263+
:micrometer-javadoc-registry-prometheus-base-url: {micrometer-javadoc-base-url}/micrometer-registry-prometheus/{version-lib-micrometer}/io/micrometer/prometheus
261264
262265
endif::attributes-included[]

docs/includes/metrics/metrics-capable-components.adoc

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,10 @@ endif::[]
7777
As you plan and write Helidon components and applications,
7878
you make some choices about exactly how your code will use metrics.
7979
This document gives some background information,
80-
describes the choices you face, explains their ramifications, and provides some code examples.
80+
describes each option and its effect, and provides some code examples.
8181
8282
== Usage
83+
This section helps you decide how incorporate metrics into your software by describing the categories of metrics usage, explaining generally how Helidon implements metrics, and illustrating how to write the metrics-related code accordingly.
8384
8485
=== Categorizing Metrics Usage
8586
We can place each Helidon component and Helidon application into one of three categories based on how it relies on metrics.
@@ -103,10 +104,10 @@ The type of module dictates the compile-time dependency you declare in the proje
103104
|metrics-dependent
104105
|===
105106
106-
Whenever possible, if your component or app uses metrics write it as metrics-capable code.
107+
Whenever possible, if your component or application uses metrics, then write it as metrics-capable code.
107108
108109
=== Understanding the Two Metrics Implementations
109-
Helidon provides two metrics implementations.
110+
Helidon provides two metrics implementations:
110111
111112
* _Full-featured_ metrics allows registering, removing, and updating metrics and observing metrics' changing values.
112113
The `helidon-metrics` component contains full-featured metrics.
@@ -292,8 +293,8 @@ Helidon returns either a full-featured `RegistryFactory` or a minimal one, depen
292293
// tag::writing-code-ending[]
293294
294295
== Examples
295-
=== An Example: Docker Images
296-
Here is an example showing how useful metrics-capable code can be.
296+
297+
The following example shows how useful metrics-capable code can be in the context of building Docker images.
297298
298299
You (or others) could assemble a Docker image with your metrics-capable app as its top layer or your metrics-capable component in a middle layer, built on a lower layer containing several Helidon modules including the full metrics implementation.
299300
When that Docker image runs, your app will run with full-featured metrics support.

docs/includes/metrics/metrics-config.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ Helidon updates and reports a metric only if two conditions hold:
8181
** there is no `include` regex pattern, or
8282
** the metric name matches the `include` pattern.
8383
84-
[CAUTION]
84+
[NOTE]
8585
====
8686
Make sure any `include` regex pattern you specify matches _all_ the metric names you want to capture.
8787
====
@@ -150,14 +150,14 @@ endif::[]
150150
151151
[#config-rest-request]
152152
ifdef::mp-flavor[]
153-
==== Enable `REST.request` metrics
153+
==== Enable `REST.request` Metrics
154154
155155
.Controlling REST request metrics
156156
[source,properties]
157157
----
158158
metrics.rest-request-enabled=true
159159
----
160-
Helidon will automatically register and update `SimpleTimer` metrics for every REST endpoint in your service.
160+
Helidon automatically registers and updates `SimpleTimer` metrics for every REST endpoint in your service.
161161
endif::[]
162162
163163
// end::config-examples[]

docs/includes/metrics/metrics-shared.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ ifdef::mp-flavor[each of these.]
5757
ifdef::se-flavor[this.]
5858
5959
=== Categorizing Types of Metrics
60-
Helidon distinguishes among three general _types_, or scopes, of metrics, as described in the MP metrics specification.
60+
Helidon distinguishes among three general _types_, or scopes, of metrics, as described in the link:{microprofile-metrics-spec-url}[MP metrics specification].
6161
6262
.Types (scopes) of metrics
6363
[%autowidth]
@@ -128,7 +128,7 @@ curl -s -H 'Accept: application/json' -X GET http://localhost:8080/metrics/
128128
}
129129
----
130130
131-
In addition to your application metrics the reports contain other
131+
In addition to your application metrics, the reports contain other
132132
metrics of interest such as system and VM information.
133133
134134
// end::usage-body[]

docs/includes/metrics/micrometer-shared.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ Note that the first config example is equivalent to the default Helidon Micromet
124124
125125
The configuration keys that are valid for the `builtin-registries` child entries depend on the type of Micrometer meter
126126
registry.
127-
For example, the Prometheus meter registry supports the `prefix` configuration setting but other meter registries might not and might support other settings.
127+
For example, support in Helidon for the link:{micrometer-javadoc-registry-prometheus-base-url}/PrometheusConfig.html[Prometheus meter registry] respects the `prefix` configuration setting but other meter registries might not and might support other settings.
128128
Refer to the documentation for the meter registry you want to configure to find out what items apply to that registry
129129
type.
130130

docs/includes/openapi.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ ifdef::se-flavor[OpenAPI support in Helidon {flavor-uc} draws its inspiration fr
2929
The OpenAPI support in Helidon {flavor-uc} performs two main tasks:
3030
3131
* Build an in-memory model of the REST API your service implements.
32-
* Expose the model in text format (typically yaml) via the `/openapi` endpoint.
32+
* Expose the model in text format (typically YAML) via the `/openapi` endpoint.
3333
3434
To construct the model, Helidon gathers information about the service API from whichever of these sources are present in the application:
3535

docs/mp/metrics/micrometer.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ include::{rootdir}/includes/metrics/micrometer-shared.adoc[tag=intro]
3636
include::{rootdir}/includes/metrics/micrometer-shared.adoc[tag=prereq]
3737
3838
== Usage
39+
Your application registers and updates Micrometer meters using annotations or direct use of the Micrometer API.
40+
41+
Your users retrieve Micrometer meters using an endpoint which Helidon creates automatically.
3942
4043
=== Registering and Updating Meters
4144
To use Micrometer support, you can simply add the Micrometer `@Timed` and `@Counted` annotations to methods in your application. Helidon automatically registers those meters with the Micrometer composite `MeterRegistry`.
@@ -50,6 +53,7 @@ include::{rootdir}/includes/metrics/micrometer-shared.adoc[tag=accessing-endpoin
5053
5154
5255
== API
56+
To incorporate Micrometer metrics into your code, you will work with two APIs: a small one specific to Helidon, and the Micrometer API itself.
5357
5458
=== The Helidon Micrometer API
5559
Helidon automatically registers and updates meters associated with methods in your service where you add the Micrometer annotations.

docs/se/metrics/micrometer.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ include::{rootdir}/includes/metrics/micrometer-shared.adoc[tags=intro]
3636
include::{rootdir}/includes/metrics/micrometer-shared.adoc[tags=prereq]
3737
3838
== Usage
39+
Your application registers and updates Micrometer meters using annotations or direct use of the Micrometer API.
40+
41+
Your users retrieve Micrometer meters using an endpoint which Helidon creates automatically.
3942
4043
=== Registering and Updating Meters
4144
Your code

0 commit comments

Comments
 (0)