Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamin-confino committed Apr 17, 2024
1 parent 921e569 commit 77b0b63
Showing 1 changed file with 29 additions and 14 deletions.
43 changes: 29 additions & 14 deletions spec/src/main/asciidoc/metrics.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,14 @@
// Andrew Rouse
// Jan Bernitt

== Integration with MicroProfile Metrics
== Integration with MicroProfile Metrics and MicroProfile Telemetry

When Microprofile Fault Tolerance and Microprofile Metrics are used together, metrics are automatically added for each of
When Microprofile Fault Tolerance is used togeather with Microprofile Metrics or MicroProfile Telemetry, metrics are automatically added for each of
the methods annotated with a `@Retry`, `@Timeout`, `@CircuitBreaker`, `@Bulkhead` or `@Fallback` annotation.

If all three of Microprofile Fault Tolerance, Microprofile Metrics, and MicroProfile Telemetry are used togeather then Microprofile Fault Tolerance
exports metrics to both Microprofile Metrics and MicroProfile Telemetry.

=== Names

The automatically added metrics follow a consistent pattern which includes the fully qualified name of the annotated method.
Expand All @@ -48,7 +51,8 @@ Implementations must ensure that if any of these annotations are present on a me
|===
| Name | `ft.invocations.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the method was called
| Tags
Expand All @@ -63,7 +67,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.retry.calls.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the retry logic was run. This will always be once per method call.
| Tags
Expand All @@ -76,7 +81,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.retry.retries.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the method was retried
| Tags
Expand All @@ -89,7 +95,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.timeout.calls.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the timeout logic was run. This will usually be once per method call, but may be zero times if the circuit breaker prevents execution or more than once if the method is retried.
| Tags
Expand All @@ -101,7 +108,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.timeout.executionDuration`

| Type | `Histogram`
| Type in mpMetrics | `Histogram`
| Type in mpTelemetry | `LongHistogram`
| Unit | Nanoseconds
| Description | Histogram of execution times for the method
| Tags
Expand All @@ -114,7 +122,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.circuitbreaker.calls.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the circuit breaker logic was run. This will usually be once per method call, but may be more than once if the method call is retried.
| Tags
Expand All @@ -129,7 +138,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.circuitbreaker.state.total`

| Type | `Gauge<Long>`
| Type in mpMetrics | `Gauge<Long>`
| Type in mpTelemetry | `ObservableLongGauge`
| Unit | Nanoseconds
| Description | Amount of time the circuit breaker has spent in each state
| Tags
Expand All @@ -155,7 +165,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.bulkhead.calls.total`

| Type | `Counter`
| Type in mpMetrics | `Counter`
| Type in mpTelemetry | `LongCounter`
| Unit | None
| Description | The number of times the bulkhead logic was run. This will usually be once per method call, but may be zero times if the circuit breaker prevented execution or more than once if the method call is retried.
| Tags
Expand All @@ -167,7 +178,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.bulkhead.executionsRunning`

| Type | `Gauge<Long>`
| Type in mpMetrics | `Gauge<Long>`
| Type in mpTelemetry | `ObservableLongGauge`
| Unit | None
| Description | Number of currently running executions
| Tags
Expand All @@ -178,7 +190,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.bulkhead.executionsWaiting`

| Type | `Gauge<Long>`
| Type in mpMetrics | `Gauge<Long>`
| Type in mpTelemetry | `ObservableLongGauge`
| Unit | None
| Description | Number of executions currently waiting in the queue
| Tags
Expand All @@ -190,7 +203,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.bulkhead.runningDuration`

| Type | `Histogram`
| Type in mpMetrics | `Histogram`
| Type in mpTelemetry | `LongHistogram`
| Unit | Nanoseconds
| Description | Histogram of the time that method executions spent running
| Tags
Expand All @@ -201,7 +215,8 @@ a| * `method` - the fully qualified method name
|===
| Name | `ft.bulkhead.waitingDuration`

| Type | `Histogram`
| Type in mpMetrics | `Histogram`
| Type in mpTelemetry | `LongHistogram`
| Unit | Nanoseconds
| Description | Histogram of the time that method executions spent waiting in the queue
| Tags
Expand Down

0 comments on commit 77b0b63

Please sign in to comment.