Skip to content

Commit 635ebfc

Browse files
authored
translator: set SpawnUpstreamSpan to true (#3102)
* translator: set SpawnUpstreamSpan to true Signed-off-by: zirain <[email protected]> * update Signed-off-by: zirain <[email protected]> --------- Signed-off-by: zirain <[email protected]>
1 parent 5bb7b3f commit 635ebfc

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

internal/xds/translator/testdata/out/xds-ir/tracing.listeners.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656
serviceName: fake-name.fake-ns
5757
randomSampling:
5858
value: 90
59+
spawnUpstreamSpan: true
5960
useRemoteAddress: true
6061
drainType: MODIFY_ONLY
6162
name: first-listener

internal/xds/translator/tracing.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import (
1515
hcm "github.com/envoyproxy/go-control-plane/envoy/extensions/filters/network/http_connection_manager/v3"
1616
tracingtype "github.com/envoyproxy/go-control-plane/envoy/type/tracing/v3"
1717
xdstype "github.com/envoyproxy/go-control-plane/envoy/type/v3"
18+
"google.golang.org/protobuf/types/known/wrapperspb"
1819
"k8s.io/utils/ptr"
1920

2021
egv1a1 "github.com/envoyproxy/gateway/api/v1alpha1"
@@ -113,7 +114,8 @@ func buildHCMTracing(tracing *ir.Tracing) (*hcm.HttpConnectionManager_Tracing, e
113114
TypedConfig: ocAny,
114115
},
115116
},
116-
CustomTags: tags,
117+
CustomTags: tags,
118+
SpawnUpstreamSpan: wrapperspb.Bool(true),
117119
}, nil
118120
}
119121

0 commit comments

Comments
 (0)