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

[SDTEST-409] Telemetry metrics data model #3734

Merged
merged 6 commits into from
Jun 26, 2024

Conversation

anmarchenko
Copy link
Member

@anmarchenko anmarchenko commented Jun 25, 2024

What does this PR do?
This PR is a first step towards full metrics support for internal Datadog telemetry.

It handles data model for the future metrics implementation:

  • Adds generate-metrics and distributions events to telemetry
  • Adds Ruby classes for every metric type we are going to support

This PR does not handle (subject for subsequent PRs):

  • metrics buffering in memory
  • multi-threaded synchronization
  • sending metrics events to the backend

Motivation:
Add telemetry metrics support in bite-sized and digestible fashion.

Additional Notes:
Pay attention to #track method in each of the metrics implementations: this is the aggregations logic that is different for every metric type.

How to test the change?
Only unit tests currently.

@github-actions github-actions bot added the core Involves Datadog core libraries label Jun 25, 2024
@anmarchenko anmarchenko force-pushed the anmarchenko/metrics_management branch from 329b91a to 5d4046c Compare June 25, 2024 10:26
@anmarchenko anmarchenko force-pushed the anmarchenko/telemetry_send_events_in_background_thread branch from 24a0409 to 5729921 Compare June 25, 2024 11:59
@anmarchenko anmarchenko force-pushed the anmarchenko/metrics_management branch 2 times, most recently from 0e68f8a to 9554754 Compare June 25, 2024 12:11
Base automatically changed from anmarchenko/telemetry_send_events_in_background_thread to master June 25, 2024 14:16
@anmarchenko anmarchenko force-pushed the anmarchenko/metrics_management branch from 9554754 to a7974f2 Compare June 25, 2024 14:46
@anmarchenko anmarchenko marked this pull request as ready for review June 25, 2024 15:01
@anmarchenko anmarchenko requested a review from a team as a code owner June 25, 2024 15:01
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 99.13793% with 2 lines in your changes missing coverage. Please review.

Project coverage is 98.11%. Comparing base (154f72e) to head (a7974f2).

Files Patch % Lines
lib/datadog/core/telemetry/event.rb 85.71% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           master    #3734    +/-   ##
========================================
  Coverage   98.10%   98.11%            
========================================
  Files        1227     1229     +2     
  Lines       73014    73246   +232     
  Branches     3508     3515     +7     
========================================
+ Hits        71633    71864   +231     
- Misses       1381     1382     +1     

☔ 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.

I read the diff and I have no objections, though I am not familiar with the product enough to leave a checkmark at this time.

@anmarchenko anmarchenko merged commit 7064144 into master Jun 26, 2024
166 checks passed
@anmarchenko anmarchenko deleted the anmarchenko/metrics_management branch June 26, 2024 06:48
@github-actions github-actions bot added this to the 2.2.0 milestone Jun 26, 2024
@TonyCTHsu TonyCTHsu mentioned this pull request Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Involves Datadog core libraries
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants