-
Notifications
You must be signed in to change notification settings - Fork 41
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
fix: keep only necessary fields for network info #467
fix: keep only necessary fields for network info #467
Conversation
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.
Left some questions, mostly looking good! I still need to test against a kibana instance (unless someone else gets to it first)
timestamp: 1612482095137858, | ||
url: 'https://vigneshh.in/', | ||
browser: { name: 'HeadlessChrome', version: '94.0.4595.0' }, | ||
step: null, |
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.
Did we not actually use the step info in the UI? I had thought we did. Even if this is the case, this seems really useful to include for ad-hoc usage by users.
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.
We do, I just removed from the fixture and only for the tests as there is none for this test.
src/plugins/network.ts
Outdated
bytes: postData?.length || 0, | ||
}, | ||
response: { | ||
statusCode: -1, |
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.
Why do we set this to -1
vs null
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.
explained below. #467 (comment)
src/plugins/network.ts
Outdated
type, | ||
method, | ||
requestSentTime: timestamp, | ||
status: -1, |
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.
We previously set this to 0
, also, why not null
? It'd be great to have a comment somewhere nearby explaining these numeric values.
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.
Hmmm good point, status: 0 denotes a successful response when the browser was having CORS issue so to avoid mistaking it for the aborted requests, I have set it to -1
which feels right.
null
would denote a separate type. Keeping number
type seems better for status codes.
Completed manual testing against a simple site, touring the Uptime browser UI nothing seems to be missing. |
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.
LGTM. Manual testing completed with heartbeat 8.2.0 using inline browser monitor.
san_list
from certificates.Yields a savings of 60kB approx. for every synthetics test run.