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

[optimizer] keep classnames to support constructor.name #113119

Merged
merged 2 commits into from
Sep 27, 2021

Conversation

spalger
Copy link
Contributor

@spalger spalger commented Sep 27, 2021

#112498 pointed out a flaw in #112435 which wasn't caught by our tests.

constructor.name is checked in our code but does not work with minified code, which caused object imports to be unable to validate the type of error they were seeing. I'm going to try and lint for this type of check so that we can prevent it in the future (we should just have a known type property or something).

For now, I'm going to disable mangling class names so that we can get this change backported to 7.16.

@spalger spalger added Team:Operations Team label for Operations Team v8.0.0 release_note:skip Skip the PR/issue when compiling release notes v7.16.0 labels Sep 27, 2021
@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
advancedSettings 874.0KB 874.4KB +418.0B
apm 2.7MB 2.7MB +1.2KB
canvas 1.0MB 1.0MB +5.0KB
cases 309.7KB 310.9KB +1.2KB
charts 41.8KB 41.8KB +10.0B
cloud 12.3KB 12.3KB +1.0B
console 361.8KB 364.9KB +3.2KB
core 132.7KB 132.4KB -308.0B
crossClusterReplication 165.2KB 167.7KB +2.5KB
dashboard 135.3KB 135.7KB +371.0B
data 101.2KB 102.5KB +1.3KB
dataEnhanced 46.3KB 46.6KB +240.0B
dataVisualizer 501.4KB 502.7KB +1.3KB
devTools 2.2KB 2.2KB +16.0B
discover 378.7KB 379.7KB +1013.0B
enterpriseSearch 1.3MB 1.3MB -308.0B
esUiShared 7.0KB 7.0KB +52.0B
expressionError 17.5KB 17.5KB +8.0B
expressionRepeatImage 1.1KB 1.1KB +12.0B
expressionRevealImage 1.8KB 1.8KB +8.0B
expressionShape 11.7KB 11.7KB +48.0B
expressionTagcloud 8.5KB 8.5KB +24.0B
fileUpload 662.3KB 662.8KB +532.0B
fleet 595.4KB 596.4KB +1023.0B
graph 403.6KB 404.5KB +934.0B
grokdebugger 58.7KB 59.2KB +435.0B
home 81.7KB 82.4KB +723.0B
indexLifecycleManagement 157.3KB 157.1KB -166.0B
indexManagement 525.9KB 527.0KB +1.1KB
indexPatternEditor 121.3KB 121.4KB +185.0B
indexPatternFieldEditor 149.3KB 151.1KB +1.8KB
indexPatternManagement 318.1KB 318.8KB +662.0B
infra 934.0KB 939.7KB +5.7KB
ingestPipelines 452.5KB 452.7KB +190.0B
inputControlVis 87.5KB 89.0KB +1.5KB
inspector 15.2KB 16.0KB +807.0B
kibanaLegacy 122.7KB 122.7KB +6.0B
kibanaOverview 9.7KB 9.7KB +50.0B
kibanaReact 203.6KB 203.4KB -193.0B
kibanaUtils 52.5KB 52.2KB -242.0B
lens 1.0MB 1.0MB +3.7KB
licenseManagement 65.4KB 65.7KB +308.0B
lists 125.1KB 125.2KB +58.0B
logstash 30.4KB 30.6KB +210.0B
management 8.8KB 8.9KB +108.0B
maps 2.6MB 2.7MB +17.8KB
mapsEms 173.7KB 174.0KB +333.0B
ml 3.5MB 3.6MB +28.5KB
monitoring 946.6KB 948.0KB +1.4KB
observability 337.0KB 337.0KB -4.0B
osquery 1.7MB 1.7MB +1.3KB
painlessLab 16.3KB 16.3KB +4.0B
presentationUtil 43.1KB 43.1KB +56.0B
remoteClusters 87.7KB 88.9KB +1.2KB
reporting 43.6KB 43.9KB +370.0B
rollup 133.9KB 134.2KB +325.0B
savedObjectsManagement 83.7KB 84.1KB +450.0B
savedObjectsTagging 42.1KB 42.3KB +160.0B
searchprofiler 159.1KB 159.1KB +40.0B
security 480.9KB 486.8KB +5.9KB
securitySolution 4.2MB 4.3MB +10.7KB
snapshotRestore 256.2KB 256.6KB +407.0B
spaces 160.0KB 161.4KB +1.4KB
stackAlerts 158.8KB 159.0KB +204.0B
timelines 233.5KB 236.9KB +3.4KB
transform 307.6KB 308.5KB +877.0B
triggersActionsUi 754.3KB 755.4KB +1.1KB
uiActionsEnhanced 128.4KB 128.8KB +391.0B
upgradeAssistant 103.8KB 104.0KB +169.0B
uptime 560.8KB 562.1KB +1.3KB
visDefaultEditor 152.1KB 152.6KB +544.0B
visTypeMarkdown 6.4KB 6.4KB +2.0B
visTypeMetric 10.2KB 10.3KB +96.0B
visTypePie 51.0KB 51.1KB +45.0B
visTypeTable 17.5KB 17.5KB +50.0B
visTypeTagcloud 2.2KB 2.2KB +2.0B
visTypeTimelion 92.3KB 92.5KB +164.0B
visTypeTimeseries 637.3KB 640.1KB +2.7KB
visTypeVega 1.9MB 1.9MB +18.0KB
visTypeVislib 376.8KB 378.2KB +1.4KB
visTypeXy 62.5KB 62.6KB +156.0B
visualizations 72.0KB 72.6KB +578.0B
visualize 51.7KB 51.8KB +133.0B
watcher 266.9KB 271.0KB +4.2KB
total +142.4KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
advancedSettings 5.6KB 5.9KB +338.0B
alerting 38.5KB 38.6KB +107.0B
apm 29.1KB 29.3KB +257.0B
apmOss 1.3KB 1.3KB +22.0B
banners 7.1KB 7.2KB +42.0B
bfetch 8.9KB 9.1KB +165.0B
canvas 16.8KB 17.0KB +141.0B
cases 80.6KB 80.8KB +252.0B
charts 59.6KB 59.9KB +314.0B
cloud 6.5KB 6.6KB +64.0B
console 16.5KB 16.6KB +65.0B
core 293.7KB 298.4KB +4.7KB
crossClusterReplication 11.8KB 11.9KB +98.0B
dashboard 184.4KB 186.1KB +1.6KB
dashboardEnhanced 14.0KB 14.7KB +745.0B
data 492.6KB 498.4KB +5.8KB
dataEnhanced 9.5KB 9.5KB +30.0B
dataVisualizer 9.0KB 9.0KB +60.0B
devTools 10.1KB 10.2KB +108.0B
discover 19.0KB 19.4KB +388.0B
discoverEnhanced 4.9KB 5.3KB +413.0B
embeddable 101.9KB 105.1KB +3.2KB
embeddableEnhanced 6.8KB 7.0KB +282.0B
enterpriseSearch 9.3KB 9.4KB +77.0B
esUiShared 125.2KB 125.7KB +502.0B
expressionError 4.8KB 4.8KB +66.0B
expressionImage 4.4KB 4.5KB +59.0B
expressionMetric 5.5KB 5.5KB +42.0B
expressionRepeatImage 6.0KB 6.1KB +65.0B
expressionRevealImage 6.4KB 6.4KB +67.0B
expressions 128.3KB 130.1KB +1.8KB
expressionShape 14.9KB 14.9KB +72.0B
expressionTagcloud 7.2KB 7.2KB +43.0B
features 4.2KB 4.4KB +235.0B
fieldFormats 46.4KB 49.1KB +2.7KB
fileUpload 11.9KB 12.2KB +302.0B
fleet 130.7KB 131.2KB +488.0B
globalSearch 8.9KB 9.2KB +331.0B
globalSearchBar 21.6KB 21.7KB +102.0B
globalSearchProviders 4.5KB 4.6KB +90.0B
graph 7.2KB 7.2KB +42.0B
grokdebugger 4.6KB 4.7KB +54.0B
home 9.7KB 10.0KB +332.0B
indexLifecycleManagement 27.7KB 28.3KB +566.0B
indexManagement 29.2KB 29.3KB +130.0B
indexPatternEditor 11.5KB 11.6KB +62.0B
indexPatternFieldEditor 18.5KB 19.0KB +464.0B
indexPatternManagement 4.1KB 4.1KB +35.0B
infra 88.6KB 89.8KB +1.2KB
ingestPipelines 12.4KB 12.6KB +248.0B
inputControlVis 5.4KB 5.4KB +60.0B
inspector 25.1KB 25.5KB +472.0B
interactiveSetup 50.6KB 50.7KB +102.0B
kibanaLegacy 45.7KB 45.7KB +54.0B
kibanaOverview 22.4KB 22.5KB +60.0B
kibanaReact 99.2KB 99.7KB +535.0B
kibanaUtils 92.2KB 93.4KB +1.1KB
lens 38.5KB 38.7KB +128.0B
licenseManagement 11.1KB 11.1KB +89.0B
licensing 8.5KB 8.7KB +180.0B
lists 3.5KB 3.5KB +12.0B
logstash 13.4KB 14.1KB +696.0B
management 9.6KB 10.0KB +486.0B
maps 44.3KB 44.9KB +572.0B
mapsEms 5.0KB 5.0KB +40.0B
ml 33.8KB 34.0KB +219.0B
monitoring 36.2KB 36.2KB -36.0B
navigation 9.7KB 9.9KB +177.0B
newsfeed 9.8KB 10.0KB +234.0B
observability 28.4KB 28.6KB +130.0B
osquery 7.3KB 7.4KB +46.0B
painlessLab 13.0KB 13.1KB +52.0B
presentationUtil 45.0KB 45.3KB +288.0B
remoteClusters 7.3KB 7.4KB +58.0B
reporting 40.1KB 40.5KB +477.0B
rollup 11.6KB 11.7KB +64.0B
runtimeFields 11.4KB 11.4KB +70.0B
savedObjects 31.5KB 32.1KB +587.0B
savedObjectsManagement 18.4KB 19.3KB +864.0B
savedObjectsTagging 17.9KB 18.3KB +382.0B
savedObjectsTaggingOss 3.7KB 3.8KB +78.0B
screenshotMode 2.1KB 2.2KB +52.0B
searchprofiler 34.4KB 34.5KB +58.0B
security 48.1KB 49.1KB +944.0B
securityOss 6.0KB 6.2KB +176.0B
securitySolution 108.4KB 108.6KB +269.0B
share 55.9KB 56.7KB +756.0B
snapshotRestore 28.4KB 28.7KB +325.0B
spaces 19.9KB 20.3KB +402.0B
stackAlerts 12.0KB 12.0KB +64.0B
telemetry 23.5KB 24.1KB +553.0B
telemetryManagementSection 12.6KB 13.0KB +410.0B
timelines 164.6KB 165.0KB +338.0B
transform 12.1KB 12.2KB +46.0B
triggersActionsUi 51.3KB 51.5KB +232.0B
uiActions 22.6KB 23.1KB +510.0B
uiActionsEnhanced 25.5KB 26.2KB +725.0B
upgradeAssistant 18.8KB 18.9KB +131.0B
uptime 24.2KB 24.8KB +634.0B
urlDrilldown 14.6KB 14.7KB +130.0B
urlForwarding 2.6KB 2.7KB +81.0B
usageCollection 4.9KB 5.1KB +187.0B
visDefaultEditor 18.6KB 18.9KB +283.0B
visTypeMarkdown 7.1KB 7.2KB +50.0B
visTypeMetric 13.7KB 13.7KB +66.0B
visTypePie 13.7KB 13.8KB +32.0B
visTypeTable 14.6KB 14.7KB +96.0B
visTypeTagcloud 6.0KB 6.0KB +44.0B
visTypeTimelion 10.3KB 10.3KB +56.0B
visTypeTimeseries 14.5KB 14.7KB +113.0B
visTypeVega 37.1KB 37.3KB +249.0B
visTypeVislib 19.6KB 19.7KB +48.0B
visTypeXy 40.9KB 41.0KB +57.0B
visualizations 32.9KB 33.4KB +569.0B
visualize 15.9KB 16.0KB +134.0B
watcher 14.7KB 14.7KB +44.0B
total +45.9KB
Unknown metric groups

miscellaneous assets size

id before after diff
maps 979.5KB 958.9KB -20.6KB
visTypeVega 550.7KB 530.1KB -20.6KB
total -41.2KB

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@spalger spalger marked this pull request as ready for review September 27, 2021 17:24
@spalger spalger requested a review from a team as a code owner September 27, 2021 17:24
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-operations (Team:Operations)

@spalger spalger added the auto-backport Deprecated - use backport:version if exact versions are needed label Sep 27, 2021
@spalger spalger merged commit 6612f2b into elastic:master Sep 27, 2021
@spalger spalger deleted the implement/optimizer-keep-classnames branch September 27, 2021 18:04
@kibanamachine
Copy link
Contributor

💔 Backport failed

Status Branch Result
7.x Commit could not be cherrypicked due to conflicts

To backport manually run:
node scripts/backport --pr 113119

spalger pushed a commit to kibanamachine/kibana that referenced this pull request Sep 27, 2021
Co-authored-by: spalger <spalger@users.noreply.github.com>
(cherry picked from commit 6612f2b)
kibanamachine added a commit that referenced this pull request Sep 27, 2021
… and (#113119) (#112498)

* [kbn/optimizer] mangle variables in optimizer bundles (#112435)

Co-authored-by: spalger <spalger@users.noreply.github.com>

* [optimizer] keep classnames to support constructor.name (#113119)

Co-authored-by: spalger <spalger@users.noreply.github.com>
(cherry picked from commit 6612f2b)

Co-authored-by: Spencer <email@spalger.com>
Co-authored-by: spalger <spalger@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed release_note:skip Skip the PR/issue when compiling release notes Team:Operations Team label for Operations Team v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants