Skip to content

Commit d0cd3ab

Browse files
pirgeowilkinsona
authored andcommitted
Refine documentation
See gh-26258
1 parent 84455f8 commit d0cd3ab

File tree

1 file changed

+13
-9
lines changed
  • spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator

1 file changed

+13
-9
lines changed

spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator/metrics.adoc

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -148,15 +148,20 @@ You can also change the interval at which metrics are sent to Datadog:
148148
[[actuator.metrics.export.dynatrace]]
149149
==== Dynatrace
150150

151-
Dynatrace offers two metrics ingest APIs, both of which are implemented for {micrometer-registry-docs}/dynatrace[Micrometer]:
151+
Dynatrace offers two metrics ingest APIs, both of which are implemented for {micrometer-registry-docs}/dynatrace[Micrometer].
152+
Config properties in the `v1` namespace only apply when exporting to the https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v1/[Timeseries v1 API].
153+
Config properties in the `v2` namespace only apply when exporting to the https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/post-ingest-metrics/[Metrics v2 API].
154+
Please note that this integration can only export to either the `v1` or `v2` version of the API at the same time.
155+
If the `device-id` (required for v1, but not used in v2) is set in the `v1` namespace, metrics will be exported to the `v1` endpoint. Otherwise, `v2` is assumed.
152156

153157
[[actuator.metrics.export.dynatrace.v2-api]]
154-
===== V2 API
158+
===== v2 API
155159

156-
The V2 API can be used in two ways:
160+
The v2 API can be used in two ways:
157161

158162
If a local OneAgent is running on the host, metrics will be automatically exported to the https://www.dynatrace.com/support/help/how-to-use-dynatrace/metrics/metric-ingestion/ingestion-methods/local-api/[local OneAgent ingest endpoint], which forwards them to the Dynatrace backend.
159-
163+
This is the default behaviour and requires no special set up.
164+
Simply include a dependency to `'io.micrometer:micrometer-registry-dynatrace'` in your project, and metrics will be exported to the local OneAgent endpoint.
160165

161166
If no local OneAgent is running, the endpoint of the https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/post-ingest-metrics/[Metrics v2 API] and an API token are required.
162167
The https://www.dynatrace.com/support/help/dynatrace-api/basics/dynatrace-api-authentication/[API token] must have the "Ingest metrics" (`metrics.ingest`) permission set.
@@ -181,14 +186,15 @@ When using the Dynatrace v2 API, the following optional features are available:
181186
* Default dimensions: Specify key-value pairs that are added to all exported metrics.
182187
If tags with the same key are specified using Micrometer, they overwrite the default dimensions.
183188

189+
184190
[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
185191
----
186192
management:
187193
metrics:
188194
export:
189195
dynatrace:
196+
# specify token and uri or leave blank for OneAgent export
190197
v2:
191-
# specify token and uri or leave blank for OneAgent export
192198
metric-key-prefix: "your.key.prefix"
193199
enrich-with-dynatrace-metadata: true
194200
default-dimensions:
@@ -200,7 +206,7 @@ If tags with the same key are specified using Micrometer, they overwrite the def
200206
===== v1 API (Legacy)
201207

202208
The Dynatrace v1 API registry pushes metrics to the configured URI periodically using the https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v1/[Timeseries v1 API].
203-
For backwards-compatibility with existing setups, `api-version` defaults to `"v1"` but can also be specified explicitly as such.
209+
For backwards-compatibility with existing setups, when `device-id` is set (required for v1, but not used in v2), metrics will be exported to the Timeseries v1 endpoint.
204210
To export metrics to {micrometer-registry-docs}/dynatrace[Dynatrace], your API token, device ID, and URI must be provided:
205211

206212
[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
@@ -221,7 +227,7 @@ For the v1 API, the base environment URI must be specified without a path as the
221227
[[actuator.metrics.export.dynatrace.version-independent-settings]]
222228
===== Version-independent settings
223229

224-
You can also change the interval at which metrics are sent to Dynatrace (works for both API versions).
230+
In addition to the API endpoint and token, you can also change the interval at which metrics are sent to Dynatrace.
225231
The default export interval is `60s`.
226232

227233
[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
@@ -249,8 +255,6 @@ The location of the Elastic server to use can be provided using the following pr
249255
host: "https://elastic.example.com:8086"
250256
----
251257

252-
253-
254258
[[actuator.metrics.export.ganglia]]
255259
==== Ganglia
256260
By default, metrics are exported to {micrometer-registry-docs}/ganglia[Ganglia] running on your local machine.

0 commit comments

Comments
 (0)