|
Lines 107-115
while (1) {
Link Here
|
| 107 |
# It could work in a first step, but then we will want to handle job that will be created from the message received |
107 |
# It could work in a first step, but then we will want to handle job that will be created from the message received |
| 108 |
my $job = Koha::BackgroundJobs->find($args->{job_id}); |
108 |
my $job = Koha::BackgroundJobs->find($args->{job_id}); |
| 109 |
|
109 |
|
|
|
110 |
$conn->ack( { frame => $frame } ); # Acknowledge the message was recieved |
| 110 |
$pm->start and next; |
111 |
$pm->start and next; |
| 111 |
$job->process( { job_id => $job->id, %$args } ); |
112 |
$job->process( { job_id => $job->id, %$args } ); |
| 112 |
$conn->ack( { frame => $frame } ); # FIXME depending on success? |
|
|
| 113 |
$pm->finish; |
113 |
$pm->finish; |
| 114 |
|
114 |
|
| 115 |
} else { |
115 |
} else { |
| 116 |
- |
|
|