From 746f0c1558e6f4d0941498e18d6b8be5deb67313 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Fri, 2 Dec 2022 14:43:27 +0100 Subject: [PATCH] Bug 32394: Restore long tasks queue We are sending "queue" as parameter, but "job_queue" is retrieved in Koha::BackgroundJob->enqueue... Test plan: Read code and confirm the above. More fun for test plan will be found on bug 32393 Signed-off-by: Tomas Cohen Arazi --- Koha/BackgroundJob/BatchCancelHold.pm | 6 +++--- Koha/BackgroundJob/BatchDeleteAuthority.pm | 6 +++--- Koha/BackgroundJob/BatchDeleteBiblio.pm | 6 +++--- Koha/BackgroundJob/BatchDeleteItem.pm | 2 +- Koha/BackgroundJob/BatchUpdateAuthority.pm | 6 +++--- Koha/BackgroundJob/BatchUpdateBiblio.pm | 6 +++--- Koha/BackgroundJob/BatchUpdateItem.pm | 6 +++--- Koha/BackgroundJob/CreateEHoldingsFromBiblios.pm | 6 +++--- Koha/BackgroundJob/MARCImportCommitBatch.pm | 6 +++--- Koha/BackgroundJob/MARCImportRevertBatch.pm | 6 +++--- Koha/BackgroundJob/StageMARCForImport.pm | 6 +++--- 11 files changed, 31 insertions(+), 31 deletions(-) diff --git a/Koha/BackgroundJob/BatchCancelHold.pm b/Koha/BackgroundJob/BatchCancelHold.pm index cf730a6d3fb..421f7b76cf8 100644 --- a/Koha/BackgroundJob/BatchCancelHold.pm +++ b/Koha/BackgroundJob/BatchCancelHold.pm @@ -135,9 +135,9 @@ sub enqueue { $self->SUPER::enqueue( { - job_size => scalar @hold_ids, - job_args => { hold_ids => \@hold_ids, reason => $args->{reason} }, - queue => 'long_tasks', + job_size => scalar @hold_ids, + job_args => { hold_ids => \@hold_ids, reason => $args->{reason} }, + job_queue => 'long_tasks', } ); } diff --git a/Koha/BackgroundJob/BatchDeleteAuthority.pm b/Koha/BackgroundJob/BatchDeleteAuthority.pm index 29c1f5b3ecf..f0688cc6b30 100644 --- a/Koha/BackgroundJob/BatchDeleteAuthority.pm +++ b/Koha/BackgroundJob/BatchDeleteAuthority.pm @@ -103,9 +103,9 @@ sub enqueue { my @record_ids = @{ $args->{record_ids} }; $self->SUPER::enqueue({ - job_size => scalar @record_ids, - job_args => {record_ids => \@record_ids,}, - queue => 'long_tasks', + job_size => scalar @record_ids, + job_args => {record_ids => \@record_ids,}, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/BatchDeleteBiblio.pm b/Koha/BackgroundJob/BatchDeleteBiblio.pm index b87d255a08c..74867c19b6b 100644 --- a/Koha/BackgroundJob/BatchDeleteBiblio.pm +++ b/Koha/BackgroundJob/BatchDeleteBiblio.pm @@ -192,9 +192,9 @@ sub enqueue { my @record_ids = @{ $args->{record_ids} }; $self->SUPER::enqueue({ - job_size => scalar @record_ids, - job_args => {record_ids => \@record_ids,}, - queue => 'long_tasks', + job_size => scalar @record_ids, + job_args => {record_ids => \@record_ids,}, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/BatchDeleteItem.pm b/Koha/BackgroundJob/BatchDeleteItem.pm index d26504d8e27..7e30c6a2af4 100644 --- a/Koha/BackgroundJob/BatchDeleteItem.pm +++ b/Koha/BackgroundJob/BatchDeleteItem.pm @@ -237,7 +237,7 @@ sub enqueue { record_ids => \@record_ids, delete_biblios => $delete_biblios, }, - queue => 'long_tasks', + job_queue => 'long_tasks', } ); } diff --git a/Koha/BackgroundJob/BatchUpdateAuthority.pm b/Koha/BackgroundJob/BatchUpdateAuthority.pm index 23079672ff7..c4625734c5c 100644 --- a/Koha/BackgroundJob/BatchUpdateAuthority.pm +++ b/Koha/BackgroundJob/BatchUpdateAuthority.pm @@ -134,9 +134,9 @@ sub enqueue { my @record_ids = @{ $args->{record_ids} }; $self->SUPER::enqueue({ - job_size => scalar @record_ids, - job_args => {mmtid => $mmtid, record_ids => \@record_ids,}, - queue => 'long_tasks', + job_size => scalar @record_ids, + job_args => {mmtid => $mmtid, record_ids => \@record_ids,}, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/BatchUpdateBiblio.pm b/Koha/BackgroundJob/BatchUpdateBiblio.pm index 5b4d6b143b1..8322962d473 100644 --- a/Koha/BackgroundJob/BatchUpdateBiblio.pm +++ b/Koha/BackgroundJob/BatchUpdateBiblio.pm @@ -142,9 +142,9 @@ sub enqueue { return unless exists $args->{record_ids}; $self->SUPER::enqueue({ - job_size => scalar @{$args->{record_ids}}, - job_args => $args, - queue => 'long_tasks', + job_size => scalar @{$args->{record_ids}}, + job_args => $args, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/BatchUpdateItem.pm b/Koha/BackgroundJob/BatchUpdateItem.pm index d389ab97e22..82d27ec34ff 100644 --- a/Koha/BackgroundJob/BatchUpdateItem.pm +++ b/Koha/BackgroundJob/BatchUpdateItem.pm @@ -154,9 +154,9 @@ sub enqueue { $self->SUPER::enqueue( { - job_size => scalar @record_ids, - job_args => {%$args}, - queue => 'long_tasks', + job_size => scalar @record_ids, + job_args => {%$args}, + job_queue => 'long_tasks', } ); } diff --git a/Koha/BackgroundJob/CreateEHoldingsFromBiblios.pm b/Koha/BackgroundJob/CreateEHoldingsFromBiblios.pm index 6ad61f33184..c57c223312c 100644 --- a/Koha/BackgroundJob/CreateEHoldingsFromBiblios.pm +++ b/Koha/BackgroundJob/CreateEHoldingsFromBiblios.pm @@ -207,9 +207,9 @@ sub enqueue { return unless exists $args->{record_ids}; $self->SUPER::enqueue({ - job_size => scalar @{$args->{record_ids}}, - job_args => $args, - queue => 'long_tasks', + job_size => scalar @{$args->{record_ids}}, + job_args => $args, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/MARCImportCommitBatch.pm b/Koha/BackgroundJob/MARCImportCommitBatch.pm index c2090617d1e..ac1c47acda7 100644 --- a/Koha/BackgroundJob/MARCImportCommitBatch.pm +++ b/Koha/BackgroundJob/MARCImportCommitBatch.pm @@ -116,9 +116,9 @@ sub enqueue { my ( $self, $args) = @_; $self->SUPER::enqueue({ - job_size => Koha::Import::Records->search({ import_batch_id => $args->{import_batch_id} })->count, - job_args => $args, - queue => 'long_tasks', + job_size => Koha::Import::Records->search({ import_batch_id => $args->{import_batch_id} })->count, + job_args => $args, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/MARCImportRevertBatch.pm b/Koha/BackgroundJob/MARCImportRevertBatch.pm index c2c81332813..b9d7c6e59c7 100644 --- a/Koha/BackgroundJob/MARCImportRevertBatch.pm +++ b/Koha/BackgroundJob/MARCImportRevertBatch.pm @@ -112,9 +112,9 @@ sub enqueue { my ( $self, $args) = @_; $self->SUPER::enqueue({ - job_size => Koha::Import::Records->search({ import_batch_id => $args->{import_batch_id} })->count, - job_args => $args, - queue => 'long_tasks', + job_size => Koha::Import::Records->search({ import_batch_id => $args->{import_batch_id} })->count, + job_args => $args, + job_queue => 'long_tasks', }); } diff --git a/Koha/BackgroundJob/StageMARCForImport.pm b/Koha/BackgroundJob/StageMARCForImport.pm index 206bb8b186c..423bc64bb57 100644 --- a/Koha/BackgroundJob/StageMARCForImport.pm +++ b/Koha/BackgroundJob/StageMARCForImport.pm @@ -197,9 +197,9 @@ sub enqueue { my ( $self, $args) = @_; $self->SUPER::enqueue({ - job_size => 0, # TODO Unknown for now? - job_args => $args, - queue => 'long_tasks', + job_size => 0, # TODO Unknown for now? + job_args => $args, + job_queue => 'long_tasks', }); } -- 2.34.1