Skip to content

RUMM-2562 Correct the way we handle orientation change events in SR#1073

Merged
mariusc83 merged 1 commit into
feature/session-replay-vofrom
mconstantin/rumm-2562/correctly-handle-orientation-change-events
Oct 6, 2022
Merged

RUMM-2562 Correct the way we handle orientation change events in SR#1073
mariusc83 merged 1 commit into
feature/session-replay-vofrom
mconstantin/rumm-2562/correctly-handle-orientation-change-events

Conversation

@mariusc83

@mariusc83 mariusc83 commented Oct 6, 2022

Copy link
Copy Markdown
Member

What does this PR do?

This PR fixes the way we are handling the orientation change for Session Replay. Previously we were handling this in a separated flow which introduced a new state into the SnapshotProcessor causing problems regarding the new view detection and the order of the records. With this new approach we are handling the OrientationChanged event in the same stack used for handling the screen snapshot and by doing this we eliminate the potential issues resulting from introducing a new state for the SnapshotProcessor.

Motivation

What inspired you to submit this pull request?

Additional Notes

Anything else we should know when reviewing?

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

@mariusc83 mariusc83 self-assigned this Oct 6, 2022
@xgouchet xgouchet added the size-small This PR is small sized label Oct 6, 2022
@codecov-commenter

codecov-commenter commented Oct 6, 2022

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 95.23810% with 1 line in your changes missing coverage. Please review.

Project coverage is 82.41%. Comparing base (ff9a1cf) to head (87fc25d).

Files with missing lines Patch % Lines
...tadog/android/sessionreplay/processor/Processor.kt 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                      Coverage Diff                      @@
##           feature/session-replay-vo    #1073      +/-   ##
=============================================================
- Coverage                      82.45%   82.41%   -0.04%     
=============================================================
  Files                            346      347       +1     
  Lines                          11179    11180       +1     
  Branches                        1849     1853       +4     
=============================================================
- Hits                            9217     9213       -4     
- Misses                          1378     1383       +5     
  Partials                         584      584              
Files with missing lines Coverage Δ
...droid/sessionreplay/processor/SnapshotProcessor.kt 93.75% <100.00%> (-0.06%) ⬇️
...d/sessionreplay/recorder/RecorderOnDrawListener.kt 86.96% <100.00%> (+0.59%) ⬆️
...tadog/android/sessionreplay/processor/Processor.kt 0.00% <0.00%> (ø)

... and 7 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mariusc83
mariusc83 marked this pull request as ready for review October 6, 2022 12:29
@mariusc83
mariusc83 requested a review from a team as a code owner October 6, 2022 12:29
}

private fun isLastFullSnapshotTime(): Boolean {
private fun resolveIsFullSnapshotTime(): Boolean {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: maybe isTimeForFullSnapshort (but yeah , this may not sound better)?

}

private fun isNewView(
private fun resolveIsNewView(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

why do we rename this? imo without resolve it also looks reasonable.

@mariusc83
mariusc83 force-pushed the mconstantin/rumm-2562/correctly-handle-orientation-change-events branch from 404a00e to 87fc25d Compare October 6, 2022 13:54
@mariusc83
mariusc83 merged commit e6b3c45 into feature/session-replay-vo Oct 6, 2022
@mariusc83
mariusc83 deleted the mconstantin/rumm-2562/correctly-handle-orientation-change-events branch October 6, 2022 14:52
@xgouchet xgouchet added this to the 1.17.0 milestone Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size-small This PR is small sized

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants