Move from ForcedSampling tags to standard DDTags based tags
MODIFY
dd-trace-api/src/main/java/datadog/trace/api/DDTags.java
dd-trace-api/src/main/java/datadog/trace/api/DDTags.java
@@ -16,4 +16,9 @@ public class DDTags {
public static final String ANALYTICS_SAMPLE_RATE = "_dd1.sr.eausr";
@Deprecated public static final String EVENT_SAMPLE_RATE = ANALYTICS_SAMPLE_RATE;
+
+ /** Manually force tracer to be keep the trace */
+ public static final String MANUAL_KEEP = "manual.keep";
+ /** Manually force tracer to be drop the trace */
+ public static final String MANUAL_DROP = "manual.drop";
}

MODIFY
dd-trace-api/src/main/java/datadog/trace/api/interceptor/MutableSpan.java
dd-trace-api/src/main/java/datadog/trace/api/interceptor/MutableSpan.java
@@ -26,8 +26,8 @@ public interface MutableSpan {
/**
* @deprecated Use {@link io.opentracing.Span#setTag(String, boolean)} instead using either tag
- * names {@link datadog.trace.api.sampling.ForcedTracing#manual_KEEP} or {@link
- * datadog.trace.api.sampling.ForcedTracing#manual_DROP}.
+ * names {@link datadog.trace.api.DDTags#MANUAL_KEEP} or {@link
+ * datadog.trace.api.DDTags#MANUAL_DROP}.
* @param newPriority
* @return
*/

DELETE
dd-trace-api/src/main/java/datadog/trace/api/sampling/ForcedTracing.java
-package datadog.trace.api.sampling;
-
-/**
- * Class exposing tag names to mark a span to be dropped or kept by the sampler based on user
- * intent.
- */
-public final class ForcedTracing {
-
- /** The user has decided to drop the trace. */
- public static final String manual_DROP = "manual.drop";
-
- /** The user has decided to keep the trace. */
- public static final String manual_KEEP = "manual.keep";
-
- private ForcedTracing() {}
-}

MODIFY
dd-trace-ot/src/main/java/datadog/opentracing/decorators/ForceManualDropDecorator.java
dd-trace-ot/src/main/java/datadog/opentracing/decorators/ForceManualDropDecorator.java
package datadog.opentracing.decorators;
import datadog.opentracing.DDSpanContext;
-import datadog.trace.api.sampling.ForcedTracing;
+import datadog.trace.api.DDTags;
import datadog.trace.api.sampling.PrioritySampling;
/**
@@ -11,7 +11,7 @@ public class ForceManualDropDecorator extends AbstractDecorator {
public ForceManualDropDecorator() {
super();
- setMatchingTag(ForcedTracing.manual_DROP);
+ setMatchingTag(DDTags.MANUAL_DROP);
}
@Override

MODIFY
dd-trace-ot/src/main/java/datadog/opentracing/decorators/ForceManualKeepDecorator.java
dd-trace-ot/src/main/java/datadog/opentracing/decorators/ForceManualKeepDecorator.java
package datadog.opentracing.decorators;
import datadog.opentracing.DDSpanContext;
-import datadog.trace.api.sampling.ForcedTracing;
+import datadog.trace.api.DDTags;
import datadog.trace.api.sampling.PrioritySampling;
/**
@@ -11,7 +11,7 @@ public class ForceManualKeepDecorator extends AbstractDecorator {
public ForceManualKeepDecorator() {
super();
- setMatchingTag(ForcedTracing.manual_KEEP);
+ setMatchingTag(DDTags.MANUAL_KEEP);
}
@Override

Move from ForcedSampling tags to standard DDTags based tags