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

Bulk Plugin Management: Disable auto updating plugins when page loads #96126

Merged
merged 2 commits into from
Nov 11, 2024

Conversation

vykes-mac
Copy link
Contributor

Related to https://github.com/Automattic/dotcom-forge/issues/9706

Proposed Changes

Currently when the list of plugins are fetched those that have autoupdate enabled immediately execute the update on page loads, we want to disable this behaviour.

  • Disable auto update when page loads

Why are these changes being made?

  • Improve performance and product quality

Testing Instructions

  • Ensure some of your plugins have autoupdate enabled
  • Go to /plugins/manage
  • Verify auto update is not executed by checking no update api calls were made

image

Pre-merge Checklist

  • Has the general commit checklist been followed? (PCYsg-hS-p2)
  • Have you written new tests for your changes?
  • Have you tested the feature in Simple (P9HQHe-k8-p2), Atomic (P9HQHe-jW-p2), and self-hosted Jetpack sites (PCYsg-g6b-p2)?
  • Have you checked for TypeScript, React or other console errors?
  • Have you used memoizing on expensive computations? More info in Memoizing with create-selector and Using memoizing selectors and Our Approach to Data
  • Have we added the "[Status] String Freeze" label as soon as any new strings were ready for translation (p4TIVU-5Jq-p2)?
  • For changes affecting Jetpack: Have we added the "[Status] Needs Privacy Updates" label if this pull request changes what data or activity we track or use (p4TIVU-aUh-p2)?

@matticbot
Copy link
Contributor

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • notifications
  • odyssey-stats
  • wpcom-block-editor

To test WordPress.com changes, run install-plugin.sh $pluginSlug update/remove-autoupdate-when-plugins-fetched on your sandbox.

@matticbot
Copy link
Contributor

matticbot commented Nov 6, 2024

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

Sections (~551 bytes removed 📉 [gzipped])

name                             parsed_size           gzip_size
stats                                 -182 B  (-0.0%)      -62 B  (-0.0%)
site-marketing                        -182 B  (-0.0%)      -67 B  (-0.0%)
settings-discussion                   -182 B  (-0.0%)      -64 B  (-0.1%)
plugins                               -182 B  (-0.0%)      -56 B  (-0.0%)
plans                                 -182 B  (-0.0%)      -59 B  (-0.0%)
marketplace                           -182 B  (-0.0%)      -56 B  (-0.0%)
marketing                             -182 B  (-0.0%)      -60 B  (-0.0%)
jetpack-social                        -182 B  (-0.0%)      -60 B  (-0.0%)
jetpack-cloud-plugin-management       -182 B  (-0.0%)      -56 B  (-0.0%)
home                                  -182 B  (-0.0%)      -59 B  (-0.0%)
email                                 -182 B  (-0.0%)      -59 B  (-0.0%)
checkout                              -182 B  (-0.0%)      -61 B  (-0.0%)
activity                              -182 B  (-0.0%)      -63 B  (-0.0%)

Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to.

Async-loaded Components (~56 bytes removed 📉 [gzipped])

name                          parsed_size           gzip_size
async-load-design-playground       -182 B  (-0.0%)      -56 B  (-0.0%)
async-load-design                  -182 B  (-0.0%)      -56 B  (-0.0%)

React components that are loaded lazily, when a certain part of UI is displayed for the first time.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

Copy link
Contributor

@paulopmt1 paulopmt1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing this sounds good to me. As we talked on Slack, can we also double-check how the current auto-update mechanism looks like? So we can proper document that in the Project Thread.

@paulopmt1
Copy link
Contributor

@vykes-mac I removed the label so it won't appear duplicated in the project items list since we're already tracking it using this issue. This will help me when creating tomorrow's summary.

@vykes-mac vykes-mac merged commit 789619f into trunk Nov 11, 2024
11 checks passed
@vykes-mac vykes-mac deleted the update/remove-autoupdate-when-plugins-fetched branch November 11, 2024 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants