Skip to content

Commit 168edff

Browse files
committed
rename to rpc.server|client.call.duration
1 parent 586981d commit 168edff

File tree

8 files changed

+72
-26
lines changed

8 files changed

+72
-26
lines changed

docs/rpc/connect-rpc.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ described on this page.
1212

1313
## Client Span
1414

15-
<!-- semconv span.rpc.connect_rpc.client -->
15+
<!-- semconv span.rpc.connect_rpc.call.client -->
1616
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
1717
<!-- see templates/registry/markdown/snippet.md.j2 -->
1818
<!-- prettier-ignore-start -->
@@ -161,7 +161,7 @@ the `rpc.connect_rpc.response.metadata.my-custom-key` attribute with value `["at
161161

162162
## Server Span
163163

164-
<!-- semconv span.rpc.connect_rpc.server -->
164+
<!-- semconv span.rpc.connect_rpc.call.server -->
165165
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
166166
<!-- see templates/registry/markdown/snippet.md.j2 -->
167167
<!-- prettier-ignore-start -->

docs/rpc/grpc.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ described on this page.
1212

1313
## Client Span
1414

15-
<!-- semconv span.rpc.grpc.client -->
15+
<!-- semconv span.rpc.grpc.call.client -->
1616
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
1717
<!-- see templates/registry/markdown/snippet.md.j2 -->
1818
<!-- prettier-ignore-start -->
@@ -162,7 +162,7 @@ the `rpc.grpc.response.metadata.my-custom-key` attribute with value `["attribute
162162

163163
## Server Span
164164

165-
<!-- semconv span.rpc.grpc.server -->
165+
<!-- semconv span.rpc.grpc.call.server -->
166166
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
167167
<!-- see templates/registry/markdown/snippet.md.j2 -->
168168
<!-- prettier-ignore-start -->

docs/rpc/json-rpc.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ described on this page.
1212

1313
## Client Span
1414

15-
<!-- semconv span.rpc.jsonrpc.client -->
15+
<!-- semconv span.rpc.jsonrpc.call.client -->
1616
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
1717
<!-- see templates/registry/markdown/snippet.md.j2 -->
1818
<!-- prettier-ignore-start -->
@@ -124,7 +124,7 @@ different processes could be listening on TCP port 12345 and UDP port 12345.
124124

125125
## Server Span
126126

127-
<!-- semconv span.rpc.jsonrpc.server -->
127+
<!-- semconv span.rpc.jsonrpc.call.server -->
128128
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
129129
<!-- see templates/registry/markdown/snippet.md.j2 -->
130130
<!-- prettier-ignore-start -->

docs/rpc/rpc-metrics.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ metrics can be filtered for finer grain analysis.
2020
- [Metric: `rpc.server.request.size`](#metric-rpcserverrequestsize)
2121
- [Metric: `rpc.server.response.size`](#metric-rpcserverresponsesize)
2222
- [RPC client](#rpc-client)
23-
- [Metric: `rpc.client.duration`](#metric-rpcclientduration)
23+
- [Metric: `rpc.client.call.duration`](#metric-rpcclientcallduration)
2424
- [Metric: `rpc.client.request.size`](#metric-rpcclientrequestsize)
2525
- [Metric: `rpc.client.response.size`](#metric-rpcclientresponsesize)
2626
- [Semantic Conventions for specific RPC technologies](#semantic-conventions-for-specific-rpc-technologies)
@@ -71,7 +71,7 @@ This metric SHOULD be specified with
7171
[`ExplicitBucketBoundaries`](https://github.com/open-telemetry/opentelemetry-specification/blob/v1.50.0/specification/metrics/api.md#instrument-advisory-parameters)
7272
of `[ 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10 ]`.
7373

74-
<!-- semconv metric.rpc.server.duration -->
74+
<!-- semconv metric.rpc.server.call.duration -->
7575
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
7676
<!-- see templates/registry/markdown/snippet.md.j2 -->
7777
<!-- prettier-ignore-start -->
@@ -80,7 +80,7 @@ of `[ 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10
8080

8181
| Name | Instrument Type | Unit (UCUM) | Description | Stability | Entity Associations |
8282
| -------- | --------------- | ----------- | -------------- | --------- | ------ |
83-
| `rpc.server.duration` | Histogram | `s` | Measures the duration of inbound remote procedure calls (RPC). [1] | ![Development](https://img.shields.io/badge/-development-blue) | |
83+
| `rpc.server.call.duration` | Histogram | `s` | Measures the duration of inbound remote procedure calls (RPC). [1] | ![Development](https://img.shields.io/badge/-development-blue) | |
8484

8585
**[1]:** When this metric is reported alongside an RPC server span, the metric value
8686
SHOULD be the same as the RPC server span duration.
@@ -366,15 +366,15 @@ different processes could be listening on TCP port 12345 and UDP port 12345.
366366

367367
Below is a list of RPC client metric instruments.
368368

369-
#### Metric: `rpc.client.duration`
369+
#### Metric: `rpc.client.call.duration`
370370

371371
This metric is [recommended][MetricRecommended].
372372

373373
This metric SHOULD be specified with
374374
[`ExplicitBucketBoundaries`](https://github.com/open-telemetry/opentelemetry-specification/blob/v1.50.0/specification/metrics/api.md#instrument-advisory-parameters)
375375
of `[ 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10 ]`.
376376

377-
<!-- semconv metric.rpc.client.duration -->
377+
<!-- semconv metric.rpc.client.call.duration -->
378378
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
379379
<!-- see templates/registry/markdown/snippet.md.j2 -->
380380
<!-- prettier-ignore-start -->
@@ -383,7 +383,7 @@ of `[ 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10
383383

384384
| Name | Instrument Type | Unit (UCUM) | Description | Stability | Entity Associations |
385385
| -------- | --------------- | ----------- | -------------- | --------- | ------ |
386-
| `rpc.client.duration` | Histogram | `s` | Measures the duration of outbound remote procedure calls (RPC). [1] | ![Development](https://img.shields.io/badge/-development-blue) | |
386+
| `rpc.client.call.duration` | Histogram | `s` | Measures the duration of outbound remote procedure calls (RPC). [1] | ![Development](https://img.shields.io/badge/-development-blue) | |
387387

388388
**[1]:** When this metric is reported alongside an RPC client span, the metric value
389389
SHOULD be the same as the RPC client span duration.

docs/rpc/rpc-spans.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ Generally, a user SHOULD NOT set `peer.service` to a fully qualified RPC service
8686

8787
### RPC client span
8888

89-
<!-- semconv span.rpc.client -->
89+
<!-- semconv span.rpc.call.client -->
9090
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
9191
<!-- see templates/registry/markdown/snippet.md.j2 -->
9292
<!-- prettier-ignore-start -->
@@ -104,6 +104,9 @@ or the RPC is terminated due to an error or cancellation.
104104
For streaming RPCs, the span covers the full lifetime of the request and/or
105105
response streams until they are closed or terminated.
106106

107+
If a transient issue happened and was retried within this RPC, the corresponding
108+
span SHOULD cover the duration of the logical call with all retries.
109+
107110
**Span name:** refer to the [Span Name](/docs/rpc/rpc-spans.md#span-name) section.
108111

109112
**Span kind** MUST be `CLIENT`.
@@ -217,7 +220,7 @@ different processes could be listening on TCP port 12345 and UDP port 12345.
217220

218221
### RPC server span
219222

220-
<!-- semconv span.rpc.server -->
223+
<!-- semconv span.rpc.call.server -->
221224
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
222225
<!-- see templates/registry/markdown/snippet.md.j2 -->
223226
<!-- prettier-ignore-start -->

model/rpc/deprecated/metrics-deprecated.yaml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,3 +74,43 @@ groups:
7474
deprecated:
7575
reason: obsoleted
7676
note: Removed, no replacement at this time.
77+
78+
- id: metric.rpc.server.duration
79+
type: metric
80+
metric_name: rpc.server.duration
81+
annotations:
82+
code_generation:
83+
metric_value_type: double
84+
stability: development
85+
instrument: histogram
86+
unit: "ms"
87+
note: |
88+
While streaming RPCs may record this metric as start-of-batch
89+
to end-of-batch, it's hard to interpret in practice.
90+
91+
**Streaming**: N/A.
92+
extends: attributes.metrics.rpc.server
93+
deprecated:
94+
reason: uncategorized
95+
note: Replaced by `rpc.server.call.duration` with unit `s`.
96+
brief: "Deprecated, use `rpc.server.call.duration` instead. Note: the unit also changed from `ms` to `s`."
97+
98+
- id: metric.rpc.client.duration
99+
type: metric
100+
metric_name: rpc.client.duration
101+
annotations:
102+
code_generation:
103+
metric_value_type: double
104+
stability: development
105+
instrument: histogram
106+
unit: "ms"
107+
note: |
108+
While streaming RPCs may record this metric as start-of-batch
109+
to end-of-batch, it's hard to interpret in practice.
110+
111+
**Streaming**: N/A.
112+
extends: attributes.metrics.rpc.client
113+
deprecated:
114+
reason: uncategorized
115+
note: Replaced by `rpc.client.call.duration` with unit `s`.
116+
brief: "Deprecated, use `rpc.client.call.duration` instead. Note: the unit also changed from `ms` to `s`."

model/rpc/metrics.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
groups:
22
# RPC Server metrics
3-
- id: metric.rpc.server.duration
3+
- id: metric.rpc.server.call.duration
44
type: metric
5-
metric_name: rpc.server.duration
5+
metric_name: rpc.server.call.duration
66
annotations:
77
code_generation:
88
metric_value_type: double
@@ -46,9 +46,9 @@ groups:
4646

4747

4848
# RPC Client metrics
49-
- id: metric.rpc.client.duration
49+
- id: metric.rpc.client.call.duration
5050
type: metric
51-
metric_name: rpc.client.duration
51+
metric_name: rpc.client.call.duration
5252
annotations:
5353
code_generation:
5454
metric_value_type: double

model/rpc/spans.yaml

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
groups:
2-
- id: span.rpc.client
2+
- id: span.rpc.call.client
33
type: span
44
stability: development
55
brief: This span represents an outgoing Remote Procedure Call (RPC).
@@ -11,6 +11,9 @@ groups:
1111
For streaming RPCs, the span covers the full lifetime of the request and/or
1212
response streams until they are closed or terminated.
1313
14+
If a transient issue happened and was retried within this RPC, the corresponding
15+
span SHOULD cover the duration of the logical call with all retries.
16+
1417
**Span name:** refer to the [Span Name](/docs/rpc/rpc-spans.md#span-name) section.
1518
1619
**Span kind** MUST be `CLIENT`.
@@ -21,7 +24,7 @@ groups:
2124
- ref: rpc.system
2225
requirement_level: required
2326

24-
- id: span.rpc.server
27+
- id: span.rpc.call.server
2528
type: span
2629
stability: development
2730
extends: rpc_service.server
@@ -43,7 +46,7 @@ groups:
4346
- ref: rpc.system
4447
requirement_level: required
4548

46-
- id: span.rpc.connect_rpc.client
49+
- id: span.rpc.connect_rpc.call.client
4750
type: span
4851
stability: development
4952
brief: This span represents an outgoing Remote Procedure Call (RPC).
@@ -64,7 +67,7 @@ groups:
6467
- ref: rpc.connect_rpc.response.metadata
6568
requirement_level: opt_in
6669

67-
- id: span.rpc.connect_rpc.server
70+
- id: span.rpc.connect_rpc.call.server
6871
type: span
6972
stability: development
7073
extends: rpc_service.server
@@ -85,7 +88,7 @@ groups:
8588
- ref: rpc.connect_rpc.response.metadata
8689
requirement_level: opt_in
8790

88-
- id: span.rpc.grpc.client
91+
- id: span.rpc.grpc.call.client
8992
type: span
9093
stability: development
9194
brief: This span represents an outgoing Remote Procedure Call (RPC).
@@ -111,7 +114,7 @@ groups:
111114
- ref: rpc.grpc.response.metadata
112115
requirement_level: opt_in
113116

114-
- id: span.rpc.grpc.server
117+
- id: span.rpc.grpc.call.server
115118
type: span
116119
stability: development
117120
extends: rpc_service.server
@@ -133,7 +136,7 @@ groups:
133136
- ref: rpc.grpc.response.metadata
134137
requirement_level: opt_in
135138

136-
- id: span.rpc.jsonrpc.client
139+
- id: span.rpc.jsonrpc.call.client
137140
type: span
138141
stability: development
139142
brief: This span represents an outgoing Remote Procedure Call (RPC).
@@ -159,7 +162,7 @@ groups:
159162
- ref: rpc.jsonrpc.error_message
160163
requirement_level: recommended
161164

162-
- id: span.rpc.jsonrpc.server
165+
- id: span.rpc.jsonrpc.call.server
163166
type: span
164167
stability: development
165168
extends: rpc.server

0 commit comments

Comments
 (0)