-
Notifications
You must be signed in to change notification settings - Fork 140
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
⚗ performance impact summary tool #755
Conversation
It appears that memory profiling is cleared when navigating on another page. To have consistent memory profiling, take measurements on each loaded pages.
Regarding the stat I would add more than the median like 95 and 99 percentile.
Is it microsecond per something? seconds? session? It would be super cool to add this to graph that to see the evolution in time. |
Maybe p75 would make sense, but 95 or 99 would just show the max value, because we don't take that many measurements.
It is plain microseconds. How much CPU time Browser SDK-located code has taken during the scenario.
Would be cool indeed :) |
await page.goto('https://en.wikipedia.org/wiki/Event_monitoring') | ||
await takeMeasurements() | ||
await page.goto('https://en.wikipedia.org/wiki/Datadog') | ||
await takeMeasurements() |
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.
I am not sure if it would be statistically better to run takeMeasurements
periodically (like every 100 ms or so) instead of triggering it manually during the scenario. WDYT?
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.
I don't think it would matter too much. I like controling when to take measurements, when the page is idle after doing something. If we didn't:
- measurements could be taken while the page is loading, when the SDK is not yet loaded, yielding not applicable results for our use-case
- measurements could be taken while some JS is running, and may impact the CPU profiling.
Cool then I would add the time it took to run the scenario as 146,665 microseconds or upload: 162,482 bytes is not the same if the scenario lasted 1h ou 2.5 seconds. |
Well, it could be the same if the scenario lasts 1h or 2.5 seconds. The impact is not proportional to the scenario duration, but more on which actions are being done during it (ex: number of new views, resources loaded, etc.) The scenario duration would not be indicative of real world SDK usage, because no human will read 5 Wikipedia articles in 2 seconds :) |
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.
Nice 👍
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.
Good job!
f455fe3
to
1ecedcd
Compare
Motivation
Evaluate the Browser SDK performance impact on a given scenario
Changes
Implement a tool to run various profilings with puppeteer. You can try it with:
Testing
Example output:
From my observations, results are quite stable in general.
I have gone over the contributing documentation.