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

Error-based replays do not continue to buffer after an initial replay is captured #8257

Closed
billyvg opened this issue May 30, 2023 · 5 comments
Assignees
Labels
Package: replay Issues related to the Sentry Replay SDK

Comments

@billyvg
Copy link
Member

billyvg commented May 30, 2023

For "error-based" sampling, we buffer the replay events until an error occurs. After an error occurs, we upload the replay and continue to record the replay and treat the rest of the replay as a "session-based" replay. After this session expires, we stop replay completely. In order to capture replays again on that browser tab, two things must occur: 1) session in session storage has to be expired and 2) user has to reload the tab.

Session-based replays will get resampled after they expire, so I think it makes sense to restart buffering mode after an error-based replay is completed.

@billyvg billyvg added Status: Backlog Package: replay Issues related to the Sentry Replay SDK labels May 30, 2023
@billyvg billyvg changed the title OnError replays do not continue to buffer after an initial replay is captured Error-based replays do not continue to buffer after an initial replay is captured May 30, 2023
@mydea
Copy link
Member

mydea commented May 31, 2023

Yes, I think I agree - expected behavior would be to start a regular session, when it's over switch back to buffering.

Thinking about this, does this also make sense for regular sessions? 🤔 so whenever a session is over (no matter why) we switch to buffering mode (unless on error sample rate is 0)? Would probably simplify this a bit.

@egissan
Copy link

egissan commented Jul 3, 2023

@mydea @billyvg Any updates on this issue? Basically it's blocking us to ditch old rrweb approach and integrate new Sentry Replays feature.

@mydea
Copy link
Member

mydea commented Jul 4, 2023

Hi @egissan. We have an open PR hopefully fixing this issue. However, as this touches a lot of code and behavior, we are giving it some extra care & review time to make sure it works as expected. We'll hopefully be able to really land it in a release soon! We'll keep this issue updated.

@egissan
Copy link

egissan commented Jul 4, 2023

Thank you for the update! 🙏
Looking forward to the release

@mydea
Copy link
Member

mydea commented Jun 17, 2024

We changed the behavior around this, I think we handle this better now!

@mydea mydea closed this as completed Jun 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: replay Issues related to the Sentry Replay SDK
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants