RUM-17613 Add integration tests for timeseries collection - #3713
Closed
satween wants to merge 4 commits into
Closed
Conversation
3 tasks
Contributor
Author
This stack of pull requests is managed by Graphite. Learn more about stacking. |
3 tasks
|
Contributor
Author
|
Instrumented run status:
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## tvaleev/feature/RUM-17613-2-timeseries-schema #3713 +/- ##
================================================================================
Coverage ? 73.38%
================================================================================
Files ? 1012
Lines ? 37094
Branches ? 6390
================================================================================
Hits ? 27221
Misses ? 8043
Partials ? 1830 🚀 New features to boost your workflow:
|
Rename the internal Timeseries interface to TimeseriesCollector and rename its implementations to DefaultTimeseriesCollector and DefaultTimeseriesCollectorFactory, propagating the new names through RumFeature, the RUM scope tree and the tests. No behaviour change. Ref: RUM-17613
satween
force-pushed
the
tvaleev/feature/RUM-17613-3-integration-tests
branch
from
August 14, 2026 13:00
53d8975 to
0c453b4
Compare
satween
force-pushed
the
tvaleev/feature/RUM-17613-2-timeseries-schema
branch
from
August 14, 2026 13:00
c932d24 to
e6e92e4
Compare
Replace the collector's four-state enum with a generation-counted state and schedule a 200 ms deferred suspension when the app leaves the foreground, so the buffered batch is written instead of dropped. Sampling only runs on a foreground view, which makes the collectInBackground switch obsolete. Ref: RUM-17613
Derive the CPU and memory timeseries schemas from _common-schema.json and replace the hand-written JSON serializers with typed event factories that populate the full common event shape (os, device, connectivity, dd, ddtags). Restrict collection through TimeseriesConfiguration.collectOnly. Ref: RUM-17613
Add a playground activity and an instrumented test that assert CPU and memory timeseries are collected, flushed on backgrounding and resumed on return to foreground. Ref: RUM-17613
satween
force-pushed
the
tvaleev/feature/RUM-17613-3-integration-tests
branch
from
August 14, 2026 13:41
0c453b4 to
43297b9
Compare
satween
force-pushed
the
tvaleev/feature/RUM-17613-2-timeseries-schema
branch
from
August 14, 2026 13:41
e6e92e4 to
1c35566
Compare
3 tasks
satween
force-pushed
the
tvaleev/feature/RUM-17613-2-timeseries-schema
branch
from
August 14, 2026 14:32
1c35566 to
a2fbff9
Compare
Contributor
Author
|
Superseded: branch renamed to |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

What does this PR do?
Adds
TimeseriesTrackingPlaygroundActivityand an instrumentedTimeseriesCollectionTestthatrun the real collection pipeline against the mock RUM server: CPU and memory batches are emitted
with the expected sample counts, leaving the foreground flushes the pending batch, nothing is
collected while backgrounded, and collection resumes on return to the foreground.
Motivation
The unit tests cover the pipeline pieces in isolation; nothing exercised the whole
executor-driven path with real readers and real lifecycle transitions, which is where the
suspend/flush timing actually matters.
Additional Notes
The integration module consumes
testFixtures(project(":features:dd-sdk-android-rum"))andexcludes
tools:unit, a JVM-only test module that must not land on the Android test classpath;gsonandjUnit4are added astestFixturesImplementationso the androidTest consumer stillhas them at runtime.
Requires a connected device or emulator:
./gradlew :instrumented:integration:connectedDebugAndroidTest.Review checklist (to be filled by reviewers)
Ref: RUM-17613