Skip to content

Commit 5a7d35d

Browse files
committed
fix
1 parent dd4b74a commit 5a7d35d

File tree

1 file changed

+8
-2
lines changed
  • instrumentation-api-incubator/src/main/java/io/opentelemetry/instrumentation/api/incubator/semconv/rpc

1 file changed

+8
-2
lines changed

instrumentation-api-incubator/src/main/java/io/opentelemetry/instrumentation/api/incubator/semconv/rpc/RpcServerMetrics.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,12 +135,18 @@ public void onEnd(Context context, Attributes endAttributes, long endNanos) {
135135
if (SemconvStability.emitOldRpcSemconv()) {
136136
Long rpcServerRequestBodySize = attributes.get(RpcSizeAttributesExtractor.RPC_REQUEST_SIZE);
137137
if (rpcServerRequestBodySize != null) {
138-
oldServerRequestSize.record(rpcServerRequestBodySize, attributes, context);
138+
oldServerRequestSize.record(
139+
rpcServerRequestBodySize,
140+
SemconvStability.getOldRpcMetricAttributes(attributes),
141+
context);
139142
}
140143

141144
Long rpcServerResponseBodySize = attributes.get(RpcSizeAttributesExtractor.RPC_RESPONSE_SIZE);
142145
if (rpcServerResponseBodySize != null) {
143-
oldServerResponseSize.record(rpcServerResponseBodySize, attributes, context);
146+
oldServerResponseSize.record(
147+
rpcServerResponseBodySize,
148+
SemconvStability.getOldRpcMetricAttributes(attributes),
149+
context);
144150
}
145151
}
146152
}

0 commit comments

Comments
 (0)