Opened 8 years ago
Last modified 4 years ago
#37799 assigned enhancement
Add progress indicator to "Upgrade Network" page
Reported by: | johnjamesjacoby | Owned by: | pcarvalho |
---|---|---|---|
Milestone: | Future Release | Priority: | normal |
Severity: | normal | Version: | |
Component: | Networks and Sites | Keywords: | has-screenshots has-patch |
Focuses: | ui, multisite | Cc: |
Description
The "Upgrade Network" page loops through sites in a network, and upgrades them 5 at a time. As primitive as this interface is, as a network admin responsible for upgrading thousands of sites, I actually don't mind the simplicity.
What would be nice, though, is some indication of how many sites there are, and how many are left until the routine is complete. Maybe this is a progress bar (can we steal that from media?) or a pie-chart, or a simple "Upgrading sites 10-15 out of 2,378" or something more encouraging like "Only 2,375 to go!"
Attachments (6)
Change History (36)
This ticket was mentioned in Slack in #core-multisite by jeremyfelt. View the logs.
8 years ago
#4
@
8 years ago
- Keywords has-ui-feedback added
I'd +1 having some indication and the current solution I think works well.
This ticket was mentioned in Slack in #core-multisite by sergey. View the logs.
8 years ago
#7
@
8 years ago
- Keywords needs-patch added; 2nd-opinion has-patch commit removed
- Milestone changed from Awaiting Review to 4.8
Translatable strings cannot be concatenated like that:
_e('Upgrading sites ' . $x . '-' . $n .' out of ' . $total_sites);
It should be a printf()
with translator comments for placeholders.
This ticket was mentioned in Slack in #forums by danhgilmore. View the logs.
8 years ago
This ticket was mentioned in Slack in #core by danhgilmore. View the logs.
7 years ago
#10
@
7 years ago
Hi everyone, I took @gma992 patch and the other ideas to improve it:
Initial screen now says how many sites are.
During the upgrades, it shows which batch is currently being processed and the total.
Final message says it has no more sites to process ( "No more sites found." ) and the count of sites upgraded. This number is just the iterator, because if an error occurs, it wp_die(), and won't proceed anymore.
#11
@
7 years ago
- Keywords needs-screenshots needs-patch removed
Note for the latest patch:
I didn't properly escaped echo ( $upper_bound )
, should I?
Also, would a progress bar be nice?
This ticket was mentioned in Slack in #core-multisite by flixos90. View the logs.
7 years ago
#14
@
7 years ago
- Milestone changed from 4.8 to Future Release
This needs more discussion on what we should do. Moving to Future Release.
#16
in reply to:
↑ 15
@
7 years ago
Replying to pcarvalho:
what kind of discussion?
As per this convo: https://wordpress.slack.com/archives/C03BVB47S/p1494263980497879
#17
follow-up:
↓ 20
@
7 years ago
I would recommend the following.
- Add a new upgrade rest endpoint to core.
- Add a jQueryUI Progress bar to this page.
- Use the sites end point to get a list of sites on network, paginated.
- Go through each site on network, one by one, making ajax calls to each site's upgrade endpoint.
There will be performance issues with this on larger network, but it is a solvable problem.
Related: #40365
#18
@
7 years ago
- Owner set to pcarvalho
- Status changed from new to assigned
Assigning ownership to mark the good-first-bug
as "claimed".
This ticket was mentioned in Slack in #core-multisite by stevenkword. View the logs.
7 years ago
#20
in reply to:
↑ 17
@
7 years ago
Replying to spacedmonkey:
- Add a jQueryUI Progress bar to this page.
I like this idea (thinking of the Regenerate Thumbnails plugin).
Looks like 'jquery-ui-progressbar' in bundled in core: https://developer.wordpress.org/reference/functions/wp_enqueue_script/
#21
@
7 years ago
37799.4.diff still applies cleanly against trunk as of July 10, 2017.
#22
@
7 years ago
- Keywords has-ui-feedback removed
I like @spacedmonkey suggestions, but I think that will obviously require some additional coordination, especially if we are to create and use a new REST API endpoint.
I think 37799.4.diff can serve as a good interim step while we work toward a total revamp of this process. As far as that particular patch, I don't think it would have any noticeable effect on performance. While it adds a call to get_blog_count()
on each load, that's a cached network option and should only updated 2x a day or whenever new sites are added/removed.
I'd prefer the current message "All done!" instead of "No more sites found." upon completion though.
#23
@
7 years ago
Hi @earnjam,
just a point on the "all done": i've changed to improve the task report (as per the comment #1 ), and also, because that screen is reached when there's no sites to update.
So, "all done!" doesn't represent the fact that there wasn't anything done.
Instead, maybe "No more sites found." can be improved? "No sites need to be updated" ?
p.
#24
@
7 years ago
The main problem I see with using the value of get_blog_count()
for this is it that returns the total count of all sites on the current network regardless of status, but the upgrade process skips any sites that are spammed, deactivated or archived. So it's not really accurate as to the total number of sites that will be upgraded. This is especially true on larger networks that have big numbers of those. For instance we have a network here with ~14,000 sites, of which several thousand are deactivated.
I think the most logical end message would be something like:
All done!
50 sites were upgraded.
10 sites were skipped.
This would keep the simple notice that the process is complete, while also adding some statistics about what just occurred. We know how many sites were actually upgraded because it's just the value of $n + count($site_ids)
on the final screen. We'd only need to query for how many sites were skipped once on the completion screen.
This ticket was mentioned in Slack in #core-multisite by spacedmonkey. View the logs.
7 years ago
#26
@
7 years ago
- Keywords good-first-bug removed
Given the complexity and lack of decision (see discussion) of this, it's clear not a good-first-bug
, so let's remove the keyword.
This ticket was mentioned in Slack in #design by boemedia. View the logs.
6 years ago
#28
@
6 years ago
- Focuses ui added
- Keywords needs-design added; ui-feedback removed
We discussed this ticket today at design ticket triage and we think this ticket can benefit from a pair of loving design eyes, so added the keyword needs-design.
"All Done!", while a hilariously simple response, could also include a nice summary of events