The script debian/scripts/koha-elasticsearch doesn't use the --commit parameter even though it should be used. The issues seem to have appeared after Bug 21872. The rebuild_opts variable should keep its previous value like is done elsewhere in the script with rebuild_opts="${rebuild_opts} but here for the processes parameter it is done like this: > rebuild_opts="--processes ${processes}" This overwrites the previous value of rebuild_opts where the --commit parameter was.
Created attachment 110032 [details] [review] Bug 26448: Don't overwrite commit parameter passed to koha-elasticsearch The "--commit" or "-c" parameter was incorrectly not used if it was passed to the koha-elasticsearch program. To test: 1) Before patch notice koha-elasticsearch --rebuild --commit 1 -v <instance> only commits every 5000 records 2) Apply patch and notice the above command commits every 1 record
Created attachment 110037 [details] [review] Bug 26448: Don't overwrite commit parameter passed to koha-elasticsearch The "--commit" or "-c" parameter was incorrectly not used if it was passed to the koha-elasticsearch program. To test: 1) Before patch notice koha-elasticsearch --rebuild --commit 1 -v <instance> only commits every 5000 records 2) Apply patch and notice the above command commits every 1 record Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Nice catch, obvious fix, moving to PQA
Pushed to master for 20.11, thanks to everybody involved!
backported to 20.05.x for 20.05.05