newrelic / newrelic-android-agent

SDK to enable instrumentation of Android mobile apps in New Relic
Apache License 2.0
13 stars 12 forks source link

[NR-265384] Implement ingest sampling configuration #234

Closed cthomas-newrelic closed 3 months ago

cthomas-newrelic commented 3 months ago

Remote logging sampling is assumed to affect the sessioni, so create a random seed at start-up that determines whether this session is sampled. Sampling is enabled when the random seed is less than or equal the configured threshold.

Adds tests.

codecov[bot] commented 3 months ago

Codecov Report

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

Project coverage is 56.08%. Comparing base (b52f7cb) to head (b85374e).

Files Patch % Lines
...ent/android/logging/LogReportingConfiguration.java 84.61% 2 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #234 +/- ## ============================================= + Coverage 56.06% 56.08% +0.02% - Complexity 3247 3253 +6 ============================================= Files 324 324 Lines 16465 16467 +2 Branches 1795 1793 -2 ============================================= + Hits 9231 9236 +5 Misses 6251 6251 + Partials 983 980 -3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.