Skip to content

Conversation

anmarchenko
Copy link
Member

What does this PR do?
Adds a NullRecorder subclass of TestVisibility::Recorder with an empty constructor and with all methods skipping tracing. When CI mode is not enabled, NullRecorder is being created to make Datadog::CI public interface work without errors.

Motivation
Recent case of TestVisibility::Recorder emitting logs in production when validating environment variables

How to test the change?
Unit tests are provided. Run a rails app with tracing enabled and check that there are no logs coming from CI module.

@anmarchenko anmarchenko requested review from a team and tonyredondo December 12, 2023 16:44
@anmarchenko anmarchenko merged commit bfbdb51 into main Dec 13, 2023
@anmarchenko anmarchenko deleted the anmarchenko/do_not_start_recorder_when_ci_disabled branch December 13, 2023 15:27
@github-actions github-actions bot added this to the 0.6.0 milestone Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants