Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Telemetry: Deduplicate log entries #4154

Merged
merged 11 commits into from
Dec 18, 2024
Merged

Telemetry: Deduplicate log entries #4154

merged 11 commits into from
Dec 18, 2024

Conversation

marcotc
Copy link
Member

@marcotc marcotc commented Nov 23, 2024

This PR removes duplicate telemetry logs sent within the same batch (currently 10s). The number of occurrences is captured in the new count field for the Log telemetry event, so we can know how many events were removed as duplicated.

Change log entry

None

@github-actions github-actions bot added the core Involves Datadog core libraries label Nov 23, 2024
@pr-commenter
Copy link

pr-commenter bot commented Nov 23, 2024

Benchmarks

Benchmark execution time: 2024-12-18 00:12:46

Comparing candidate commit fcde76a in PR branch dedup-logs with baseline commit 61ca49f in branch master.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 31 metrics, 2 unstable metrics.

@marcotc marcotc marked this pull request as ready for review November 26, 2024 01:56
@marcotc marcotc requested a review from a team as a code owner November 26, 2024 01:56
Base automatically changed from disable-env-logs to master December 6, 2024 19:17
Copy link

github-actions bot commented Dec 6, 2024

Thank you for updating Change log entry section 👏

Visited at: 2024-12-13 19:02:47 UTC

@marcotc marcotc added the dev/internal Other internal work that does not need to be included in the changelog label Dec 13, 2024
@datadog-datadog-prod-us1
Copy link
Contributor

datadog-datadog-prod-us1 bot commented Dec 13, 2024

Datadog Report

Branch report: dedup-logs
Commit report: fcde76a
Test service: dd-trace-rb

✅ 0 Failed, 22127 Passed, 1475 Skipped, 5m 26.16s Total Time

@codecov-commenter
Copy link

codecov-commenter commented Dec 13, 2024

Codecov Report

Attention: Patch coverage is 98.47716% with 3 lines in your changes missing coverage. Please review.

Project coverage is 97.75%. Comparing base (ef81a2f) to head (35c01fb).

Files with missing lines Patch % Lines
lib/datadog/core/telemetry/event.rb 92.10% 3 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           master    #4154    +/-   ##
========================================
  Coverage   97.75%   97.75%            
========================================
  Files        1355     1355            
  Lines       82007    82192   +185     
  Branches     4207     4217    +10     
========================================
+ Hits        80164    80349   +185     
  Misses       1843     1843            

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@p-datadog p-datadog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should the worker spec contain a test for metrics?

lib/datadog/core/telemetry/event.rb Outdated Show resolved Hide resolved
spec/datadog/core/telemetry/event_spec.rb Show resolved Hide resolved
@marcotc marcotc enabled auto-merge December 17, 2024 23:38
@marcotc marcotc merged commit 11b9ae1 into master Dec 18, 2024
337 of 339 checks passed
@marcotc marcotc deleted the dedup-logs branch December 18, 2024 00:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Involves Datadog core libraries dev/internal Other internal work that does not need to be included in the changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants