RUM-971: Report ApplicationLaunch view even if first RUM event is not interaction#1591
Merged
0xnm merged 1 commit intoAug 31, 2023
Merged
Conversation
0xnm
force-pushed
the
nogorodnikov/rum-971/application-start-is-not-reported
branch
from
August 29, 2023 15:05
beaae57 to
8090ec4
Compare
Codecov Report
@@ Coverage Diff @@
## develop #1591 +/- ##
===========================================
+ Coverage 83.46% 83.57% +0.12%
===========================================
Files 443 443
Lines 15118 15122 +4
Branches 2262 2264 +2
===========================================
+ Hits 12617 12638 +21
+ Misses 1894 1880 -14
+ Partials 607 604 -3
|
0xnm
marked this pull request as ready for review
August 29, 2023 15:26
jonathanmos
previously approved these changes
Aug 30, 2023
mariusc83
previously approved these changes
Aug 31, 2023
0xnm
dismissed stale reviews from mariusc83, jonathanmos, and xgouchet
via
August 31, 2023 07:55
e58100d
0xnm
force-pushed
the
nogorodnikov/rum-971/application-start-is-not-reported
branch
from
August 31, 2023 07:55
8090ec4 to
e58100d
Compare
xgouchet
approved these changes
Aug 31, 2023
0xnm
deleted the
nogorodnikov/rum-971/application-start-is-not-reported
branch
August 31, 2023 08:19
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?
Fixes #1582 and maybe fixes #1523.
This PR fixes the issue when
ApplicationLaunchis not reported in case if first RUM event coming is not interaction event. In this case session is not yet active, so we createApplicationLaunchandApplicationStartedaction for nothing - they won't be written, because writer is no-op.This PR moves the logic of creating
ApplicationStartedevent up to the application scope, which makes sense - we have to report it only once in the application lifecycle. Also session we be activated onceApplicationStartedevent is received by the session scope, meaning that session is created not only by start view or start action events (which makes sense, because we introducedApplicationLaunchview to be independent from background tracking feature).There is one leftover which I don't personally enjoy - having
applicationDisplayedproperty in the scopes (I think this property is vague), but getting rid of it is tricky.Review checklist (to be filled by reviewers)