Hi Frederic, i think this is a duplicate to a new bug from yesterday: bug 31969 *** This bug has been marked as a duplicate of bug 31969 ***
Created attachment 142609 [details] [review] Bug 31970 - background_jobs_purge.pl to purge background jobs queue With this script, you can see the state of the background jobs queue, finished jobs only, and delete entries, globally, or by job type. Koha::BackgroundJob is extended with a purge() method which could be used from Koha WUI. TO TEST : - On a Koha instance with a populated background_jobs table. - Go in misc/cronjobs directory. - ./background_jobs_purge.pl Display script usage. List of job's types is displayed. - ./background_jobs_purge.pl all 2 --verbose Display a list of jobs (all types) to be deleted. - ./background_jobs_purge.pl all 2 --verbose --confirm Display a list of jobs (all types) that have been deleted. - ./background_jobs_purge.pl all 2 --verbose --confirm Display a message: No job to purge - ./background_jobs_purge.pl update_elastic_index 0 -v Display a list of all update_elastic_index job - ./background_jobs_purge.pl update_elastic_index 0 -v -c Display a list of all update_elastic_index job that have been delete. This could be run several time each day...
Katrin, yes, it is! Even it's a different approach.
Maybe you should post your patch as an alternate on bug 31969 so it's seen and highlight the differences. With the duplicate status it's now easy to miss and it looks like we should agree on one approach or the other :)
Thank you Katrin for your vigilance. Bug 31969 approach is fine for me, and it avoid adding a new script.