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

RUMM-303 Logging sampling rate #1045

Merged
merged 11 commits into from
Nov 15, 2022

Conversation

maciejburda
Copy link
Member

@maciejburda maciejburda commented Nov 8, 2022

What and why?

Adds capability of sampling logs. It was pointed out in the Github issue that this feature already exists in Android.

How?

Added implementation allows configuring sampling rate for logging both globally from configuration and locally for logger using builder.

Review checklist

  • Feature or bugfix MUST have appropriate tests (unit, integration)
  • Make sure each commit and the PR mention the Issue number or JIRA reference
  • Add CHANGELOG entry for user facing changes

Custom CI job configuration (optional)

  • Run unit tests
  • Run integration tests
  • Run smoke tests

@maciejburda maciejburda requested a review from a team as a code owner November 8, 2022 15:28
@datadog-datadog-prod-us1
Copy link

datadog-datadog-prod-us1 bot commented Nov 8, 2022

Datadog Report

Branch report: maciey/RUMM-303-logging-sampling-rate
Commit report: ff4baf2

dd-sdk-ios 0 Failed, 0 New Flaky, 1909 Passed, 0 Skipped, 4m 43.32s Wall Time

Copy link
Member

@maxep maxep left a comment

Choose a reason for hiding this comment

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

Thanks, @maciejburda 👏

It's great to be able to have a global sampling rate in Datadog.Configuration and be able to override that in any Logger instance 👍 Also, the tests and objc interface looks great!

I see 2 things:

  1. We can align with other sampling rate and make it non-optional, it will simplify things.
  2. The sampling rate should be applied to RemoteLogger only, but all log entries to the ConsoleLogger should print.

Copy link
Member

@ncreated ncreated left a comment

Choose a reason for hiding this comment

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

Really well done 🏅👍 - all changes make sense and tests coverage is nice 👌.

I left few minor feedbacks, but I don't see major blockers. Good to go after addressing @maxep 's feedback 🚀.

@maciejburda
Copy link
Member Author

@ncreated @maxep I addressed all the comments. Please give it another round 🙏

Copy link
Member

@ncreated ncreated left a comment

Choose a reason for hiding this comment

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

Awesome 🚀 - looks good and reads easy 👍.

Copy link
Member

@maxep maxep left a comment

Choose a reason for hiding this comment

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

Looks great, thank you 👍

@maciejburda maciejburda merged commit 4fee0f2 into develop Nov 15, 2022
@maciejburda maciejburda deleted the maciey/RUMM-303-logging-sampling-rate branch November 16, 2022 10:10
@maciejburda maciejburda mentioned this pull request Jan 5, 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.

3 participants