Skip to content

Commit

Permalink
fix:fix caller disposable metadata handle when using tracing. (#1477)
Browse files Browse the repository at this point in the history
  • Loading branch information
SkyeBeFreeman authored Dec 9, 2024
1 parent c3af5b9 commit 052f6cd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,4 @@
- [fix:fix auth not effected bug.](https://github.com/Tencent/spring-cloud-tencent/pull/1465)
- [feat:upgrade trace plugin.](https://github.com/Tencent/spring-cloud-tencent/pull/1469)
- [feat:support smooth upgrade from tsf.](https://github.com/Tencent/spring-cloud-tencent/pull/1473)
- [fix:fix caller disposable metadata handle when using tracing.](https://github.com/Tencent/spring-cloud-tencent/pull/1477)
Original file line number Diff line number Diff line change
Expand Up @@ -166,9 +166,11 @@ public static void init(Map<String, String> dynamicTransitiveMetadata, Map<Strin
}
// caller disposable metadata to caller custom disposable metadata
MetadataContainer metadataContainerDownstream = metadataManager.getMetadataContainer(MetadataType.CUSTOM, false);
MetadataContainer callerCustomMetadataContainer = metadataManager.getMetadataContainer(MetadataType.CUSTOM, true);
if (!CollectionUtils.isEmpty(dynamicDisposableMetadata)) {
for (Map.Entry<String, String> entry : dynamicDisposableMetadata.entrySet()) {
metadataContainerDownstream.putMetadataStringValue(entry.getKey(), entry.getValue(), TransitiveType.NONE);
callerCustomMetadataContainer.putMetadataStringValue(entry.getKey(), entry.getValue(), TransitiveType.DISPOSABLE);
}
}
// caller application metadata to caller application disposable metadata
Expand Down

0 comments on commit 052f6cd

Please sign in to comment.