-
Notifications
You must be signed in to change notification settings - Fork 953
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
Bundle analyzer on plugins #9320
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Ruchi Sharma <[email protected]>
ℹ️ Manual Changeset Creation ReminderPlease ensure manual commit for changeset file 9320.yml under folder changelogs/fragments to complete this PR. If you want to use the available OpenSearch Changeset Bot App to avoid manual creation of changeset file you can install it in your forked repository following this link. For more information about formatting of changeset files, please visit OpenSearch Auto Changeset and Release Notes Tool. |
❌ Changeset File Not Added YetPlease ensure manual commit for changeset file 9320.yml under folder changelogs/fragments to complete this PR. File still missing. |
❌ Changelog Entry Missing HyphenChangelog entries must begin with a hyphen (-). |
Signed-off-by: Ruchi Sharma <[email protected]>
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 these bundle size limits? Can you share how these number comes up? Why are we deleting some?
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.
Actually, these are not deleted manually. The file was updated 4 years back with old plugins, which are not supported now. This is all auto updated with new plugins and relevant package size only.
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.
ruchidh#3 - forked pr with results
❌ Invalid Prefix For Manual Changeset CreationInvalid description prefix. Found "feature". Only "skip" entry option is permitted for manual commit of changeset files. If you were trying to skip the changelog entry, please use the "skip" entry option in the ##Changelog section of your PR description. |
❌ Invalid Prefix For Manual Changeset CreationInvalid description prefix. Found "feature". Only "skip" entry option is permitted for manual commit of changeset files. If you were trying to skip the changelog entry, please use the "skip" entry option in the ##Changelog section of your PR description. |
1 similar comment
❌ Invalid Prefix For Manual Changeset CreationInvalid description prefix. Found "feature". Only "skip" entry option is permitted for manual commit of changeset files. If you were trying to skip the changelog entry, please use the "skip" entry option in the ##Changelog section of your PR description. |
const delta = metric.value - metric.limit; | ||
const deltaPercentage = Math.round((delta / metric.limit) * 100 * 100) / 100; | ||
|
||
if (deltaPercentage > 20) { |
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.
This percentage seems quite high. For reference, if we had 5 PRs that increased the bundle size by 15% we'd get no notification and would have more than doubled the bundle size.
: metric.value + DEFAULT_BUDGET; | ||
existingLimit != null && existingLimit >= metric.value ? existingLimit : metric.value; | ||
|
||
// Update the bundle size variation file for bundles that exceed the limit by more than 20%. |
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.
Is this to update the baseline or for reporting to the CI for it to decide whether or not to fail?
Description
This PR will create bundle variation percentage report in pr comment for a newly added performance testing from existing limit size of bundle for every Open PR against main. If the variation is more than 20%, you will see the list of plugins name which are breaking the thereshold of bundle size limit variation in comments.
Limit is updated with package size to current date.
For any plugin from now on, if have bundle size variation more than 20% will get report.
Screenshot
No required
Testing the changes
Changelog
Check List
yarn test:jest
yarn test:jest_integration