Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ public void start() {
} else {
currentLowRateFlushInterval = uploadFlushInterval;
}
LOGGER.debug("Scheduling low rate debugger sink flush to {}ms", currentLowRateFlushInterval);
lowRateScheduled =
lowRateScheduler.scheduleAtFixedRate(
this::lowRateFlush, this, 0, currentLowRateFlushInterval, TimeUnit.MILLISECONDS);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ public final class DebuggerConfig {
"dynamic.instrumentation.upload.timeout";
public static final String DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL =
"dynamic.instrumentation.upload.flush.interval";
public static final String DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS =
"dynamic.instrumentation.upload.interval.seconds";
public static final String DYNAMIC_INSTRUMENTATION_UPLOAD_BATCH_SIZE =
"dynamic.instrumentation.upload.batch.size";
public static final String DYNAMIC_INSTRUMENTATION_MAX_PAYLOAD_SIZE =
Expand Down
17 changes: 13 additions & 4 deletions internal-api/src/main/java/datadog/trace/api/Config.java
Original file line number Diff line number Diff line change
Expand Up @@ -1678,10 +1678,19 @@ PROFILING_DATADOG_PROFILER_ENABLED, isDatadogProfilerSafeInCurrentEnvironment())
dynamicInstrumentationUploadTimeout =
configProvider.getInteger(
DYNAMIC_INSTRUMENTATION_UPLOAD_TIMEOUT, DEFAULT_DYNAMIC_INSTRUMENTATION_UPLOAD_TIMEOUT);
dynamicInstrumentationUploadFlushInterval =
configProvider.getInteger(
DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL,
DEFAULT_DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL);
if (configProvider.isSet(DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS)) {
dynamicInstrumentationUploadFlushInterval =
(int)
(configProvider.getFloat(
DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS,
DEFAULT_DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL)
* 1000);
} else {
dynamicInstrumentationUploadFlushInterval =
configProvider.getInteger(
DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL,
DEFAULT_DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL);
}
dynamicInstrumentationClassFileDumpEnabled =
configProvider.getBoolean(
DYNAMIC_INSTRUMENTATION_CLASSFILE_DUMP_ENABLED,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_PR
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_SNAPSHOT_URL
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_UPLOAD_BATCH_SIZE
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_UPLOAD_TIMEOUT
import static datadog.trace.api.config.DebuggerConfig.DYNAMIC_INSTRUMENTATION_VERIFY_BYTECODE
import static datadog.trace.api.config.DebuggerConfig.EXCEPTION_REPLAY_ENABLED
Expand Down Expand Up @@ -256,7 +257,7 @@ class ConfigTest extends DDSpecification {
prop.setProperty(DYNAMIC_INSTRUMENTATION_ENABLED, "true")
prop.setProperty(DYNAMIC_INSTRUMENTATION_PROBE_FILE, "file location")
prop.setProperty(DYNAMIC_INSTRUMENTATION_UPLOAD_TIMEOUT, "10")
prop.setProperty(DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL, "1000")
prop.setProperty(DYNAMIC_INSTRUMENTATION_UPLOAD_INTERVAL_SECONDS, "0.234")
prop.setProperty(DYNAMIC_INSTRUMENTATION_UPLOAD_BATCH_SIZE, "200")
prop.setProperty(DYNAMIC_INSTRUMENTATION_METRICS_ENABLED, "false")
prop.setProperty(DYNAMIC_INSTRUMENTATION_CLASSFILE_DUMP_ENABLED, "true")
Expand Down Expand Up @@ -352,7 +353,7 @@ class ConfigTest extends DDSpecification {
config.getFinalDebuggerSnapshotUrl() == "http://somehost:123/debugger/v1/input"
config.dynamicInstrumentationProbeFile == "file location"
config.dynamicInstrumentationUploadTimeout == 10
config.dynamicInstrumentationUploadFlushInterval == 1000
config.dynamicInstrumentationUploadFlushInterval == 234
config.dynamicInstrumentationUploadBatchSize == 200
config.dynamicInstrumentationMetricsEnabled == false
config.dynamicInstrumentationClassFileDumpEnabled == true
Expand Down