Skip to content

Commit

Permalink
Include lastParentId when resetting ContextInterpreter state (#7243)
Browse files Browse the repository at this point in the history
clear lastParentId
  • Loading branch information
am312 committed Jun 26, 2024
1 parent b6b3c7f commit 42fde89
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@
import java.util.Map;
import java.util.TreeMap;

/**
* When adding new context fields to the ContextInterpreter class remember to clear them in the
* reset() method.
*/
public abstract class ContextInterpreter implements AgentPropagation.KeyClassifier {
private TraceConfig traceConfig;

Expand Down Expand Up @@ -235,6 +239,7 @@ public ContextInterpreter reset(TraceConfig traceConfig) {
|| this.clientIpResolutionEnabled && ActiveSubsystems.APPSEC_ACTIVE;
headerTags = traceConfig.getRequestHeaderTags();
baggageMapping = traceConfig.getBaggageMapping();
lastParentId = null;
return this;
}

Expand Down

0 comments on commit 42fde89

Please sign in to comment.