Skip to content

Commit

Permalink
Remove rpc.grpc.full_method tag
Browse files Browse the repository at this point in the history
  • Loading branch information
manuel-alvarez-alvarez committed Jun 12, 2024
1 parent a19b78b commit dfaca4b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ public class GatewayBridge {
private static final Pattern QUERY_PARAM_VALUE_SPLITTER = Pattern.compile("=");
private static final Pattern QUERY_PARAM_SPLITTER = Pattern.compile("&");
private static final Map<String, List<String>> EMPTY_QUERY_PARAMS = Collections.emptyMap();
private static final String GRPC_FULL_METHOD_NAME_TAG = "rpc.grpc.full_method";

/** User tracking tags that will force the collection of request headers */
private static final String[] USER_TRACKING_TAGS = {
Expand Down Expand Up @@ -370,9 +369,6 @@ public void init() {
if (ctx == null || method == null || method.isEmpty()) {
return NoopFlow.INSTANCE;
}
// set the tag used by the backend to generate the grpc pass-lists
TraceSegment segment = ctx_.getTraceSegment();
segment.setTagCurrent(GRPC_FULL_METHOD_NAME_TAG, method);
while (true) {
DataSubscriberInfo subInfo = grpcServerMethodSubInfo;
if (subInfo == null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ class ServerMethodTest extends AbstractSpringBootWithGRPCAppSecTest {
[
parameters: [
inputs: [[address: 'grpc.server.method']],
list : ['/smoketest.Greeter/Hello'],
regex : 'Greeter',
],
operator : 'phrase_match',
operator : 'match_regex',
]
],
transformers: [],
Expand Down Expand Up @@ -66,6 +66,5 @@ class ServerMethodTest extends AbstractSpringBootWithGRPCAppSecTest {
match != null
match['parameters'][0]['address'] == 'grpc.server.method'
match['parameters'][0]['value'] == 'smoketest.Greeter/Hello'
grpcRootSpan.meta['rpc.grpc.full_method'] == 'smoketest.Greeter/Hello'
}
}

0 comments on commit dfaca4b

Please sign in to comment.