diff --git a/ddtrace/debugging/_debugger.py b/ddtrace/debugging/_debugger.py index 03bab05516f..341e232cb39 100644 --- a/ddtrace/debugging/_debugger.py +++ b/ddtrace/debugging/_debugger.py @@ -400,9 +400,6 @@ def _probe_injection_hook(self, module: ModuleType) -> None: def _inject_probes(self, probes: List[LineProbe]) -> None: for probe in probes: if probe not in self._probe_registry: - if len(self._probe_registry) >= di_config.max_probes: - log.warning("Too many active probes. Ignoring new ones.") - return log.debug("[%s][P: %s] Received new %s.", os.getpid(), os.getppid(), probe) self._probe_registry.register(probe) @@ -529,10 +526,6 @@ def _probe_wrapping_hook(self, module: ModuleType) -> None: def _wrap_functions(self, probes: List[FunctionProbe]) -> None: for probe in probes: - if len(self._probe_registry) >= di_config.max_probes: - log.warning("Too many active probes. Ignoring new ones.") - return - self._probe_registry.register(probe) try: assert probe.module is not None # nosec diff --git a/ddtrace/internal/settings/dynamic_instrumentation.py b/ddtrace/internal/settings/dynamic_instrumentation.py index 99431165d5a..2ee9a3072c3 100644 --- a/ddtrace/internal/settings/dynamic_instrumentation.py +++ b/ddtrace/internal/settings/dynamic_instrumentation.py @@ -11,7 +11,6 @@ from ddtrace.version import get_version -DEFAULT_MAX_PROBES = 100 DEFAULT_GLOBAL_RATE_LIMIT = 100.0 @@ -49,7 +48,6 @@ class DynamicInstrumentationConfig(DDConfig): service_name = DDConfig.d(str, lambda _: ddconfig.service or get_application_name() or DEFAULT_SERVICE_NAME) _intake_url = DDConfig.d(str, lambda _: agent_config.trace_agent_url) - max_probes = DDConfig.d(int, lambda _: DEFAULT_MAX_PROBES) global_rate_limit = DDConfig.d(float, lambda _: DEFAULT_GLOBAL_RATE_LIMIT) _tags_in_qs = DDConfig.d(bool, lambda _: True) tags = DDConfig.d(str, _derive_tags) diff --git a/tests/debugging/exploration/debugger.py b/tests/debugging/exploration/debugger.py index a1d7eed0305..c5e6dd3566d 100644 --- a/tests/debugging/exploration/debugger.py +++ b/tests/debugging/exploration/debugger.py @@ -198,7 +198,6 @@ def on_snapshot(cls, snapshot: Snapshot) -> None: @classmethod def enable(cls) -> None: - di_config.max_probes = float("inf") di_config.global_rate_limit = float("inf") di_config.metrics = False diff --git a/tests/debugging/test_debugger.py b/tests/debugging/test_debugger.py index 8f4e4678201..07299f56168 100644 --- a/tests/debugging/test_debugger.py +++ b/tests/debugging/test_debugger.py @@ -324,25 +324,6 @@ def test_debugger_decorated_method(stuff): ) -@mock.patch("ddtrace.debugging._debugger.log") -def test_debugger_max_probes(mock_log): - with debugger(max_probes=1) as d: - d.add_probes( - good_probe(), - ) - assert len(d._probe_registry) == 1 - d.add_probes( - create_snapshot_line_probe( - probe_id="probe-decorated-method", - source_file="tests/submod/stuff.py", - line=48, - condition=None, - ), - ) - assert len(d._probe_registry) == 1 - mock_log.warning.assert_called_once_with("Too many active probes. Ignoring new ones.") - - def test_debugger_tracer_correlation(stuff): with debugger() as d: d.add_probes(