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

dev/core#2310 Searchkit - Perform bulk updates in batches; improve user feedback. #19425

Merged
merged 1 commit into from Jan 29, 2021

Conversation

colemanw
Copy link
Member

Overview

https://lab.civicrm.org/dev/core/-/issues/2310

Adds a batch system to search kit. This avoids server timeouts, and improves the user experience.

Before

Simple save button processes all records at once with no user feedback.

After

Processes bulk updates/deletes 500 at a time, with a progress bar, spinner & text to indicate which records are being processed.

image

Technical Details

This breaks the batches into groups of 500 records at a time. That number is currently a hard-coded constant. I guess we could make it a setting if needed.

@civibot
Copy link

civibot bot commented Jan 20, 2021

(Standard links)

@civibot civibot bot added the master label Jan 20, 2021
Simple batch system to avoid server timeouts, processes bulk updates/deletes 500 at a time,
with a progress bar, spinner & text to indicate which records are being processed.
@eileenmcnaughton
Copy link
Contributor

Ohh this is exciting - I can't kick the tyres until next week though

@eileenmcnaughton
Copy link
Contributor

@colemanw this is nice.

I experience a real lag in the other fields in the screen - this is the before screen shot - note how long it takes for the field to change to a hand - campaign is also fairly slow (there are quite a few). I originally thought it was worse after but I'm not so sure now. I think it warrants further investigation but is non-blocking on this

Before
before2021-01-30 12-32

After
after2021-01-30 12-38

@eileenmcnaughton eileenmcnaughton merged commit ffa43bd into civicrm:master Jan 29, 2021
@eileenmcnaughton eileenmcnaughton deleted the searchBulkActions branch January 29, 2021 23:42
@colemanw
Copy link
Member Author

colemanw commented Jan 30, 2021

@eileenmcnaughton I think the slow lag when opening up the "Add Value" select is due to it waiting on an ajax Contribution.getFields happening in the background to populate that list. I'm not sure why that call is taking so long but I would guess it is due to an excessively long pseudoconstant list in one or more of the fields... perhaps there are a lot of campaigns?

@colemanw
Copy link
Member Author

@eileenmcnaughton I think this will help with your loading time issue: #19463

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants