-
Notifications
You must be signed in to change notification settings - Fork 142
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
[RUMF-976] add info to monitor failing xhr fallback #1035
Conversation
5e4851e
to
7108062
Compare
7108062
to
c906de7
Compare
@@ -52,7 +52,7 @@ export class HttpRequest { | |||
request: { | |||
status: req.status, | |||
ready_state: req.readyState, | |||
response_text: req.responseText.slice(0, 64), | |||
response_text: req.responseText.slice(0, 256), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are we confident that it will be enough?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hum, I made it 512 to be sure. FUI the message currently cuts at "... error:", so all the rest will be the error message.
Codecov Report
@@ Coverage Diff @@
## main #1035 +/- ##
=======================================
Coverage 88.93% 88.93%
=======================================
Files 88 88
Lines 4166 4168 +2
Branches 958 959 +1
=======================================
+ Hits 3705 3707 +2
Misses 461 461
Continue to review full report at Codecov.
|
Motivation
The browser SDK uses sendBeacon() when available and the size < (16KB for rum, 60ko for replay). If not, it falls back to XMLHttpRequest. In some cases the XHR requests fail. This PR adds some information in the internal monitoring to better understand the reasons of this issue.
Changes
Testing
Unit, Locally
I have gone over the contributing documentation.