-
Notifications
You must be signed in to change notification settings - Fork 277
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduce trace.datadog.tags.enabled
- Loading branch information
Showing
14 changed files
with
381 additions
and
235 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
dd-trace-core/src/main/java/datadog/trace/core/propagation/DatadogTagsNoop.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package datadog.trace.core.propagation; | ||
|
||
import java.util.Map; | ||
|
||
/** Noop implementation of DatadogTags. It's used when x-datadog-tags propagation is disabled. */ | ||
class DatadogTagsNoop extends DatadogTags { | ||
|
||
static DatadogTags INSTANCE = new DatadogTagsNoop(); | ||
|
||
private DatadogTagsNoop() {} | ||
|
||
@Override | ||
public void updateUpstreamServices(String serviceName, int priority, int mechanism, double rate) { | ||
// noop impl, do nothing | ||
} | ||
|
||
@Override | ||
public boolean isEmpty() { | ||
// always empty | ||
return true; | ||
} | ||
|
||
@Override | ||
public String encodeAsHeaderValue() { | ||
return ""; | ||
} | ||
|
||
@Override | ||
public Map<String, String> parseAndMerge() { | ||
return null; | ||
} | ||
} |
Oops, something went wrong.