https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30943

--- Comment #12 from Tomás Cohen Arazi <tomasco...@gmail.com> ---
(In reply to Marcel de Rooy from comment #11)
> Please read the history on both bugs.

On bug 32305, they discuss the Koha::BackgroundJob->process method, making it
not initiate a background job unless its status is 'new()', with different
approaches and in discussion, as you noticed.

This bug is only taking care of making already existing helpers be used to
reduce the amount of unnecessary code, like this:

-    my $job_progress = 0;
-    $self->started_on(dt_from_string)->progress($job_progress)
-      ->status('started')->store;
+    $self->start;

the place in which they might have an intersection, is that ->start will raise
an exception if the status is not new().

We don't have a 'retry' mechanism on failure and we don't have a proper way to
deal with stale/wrong messages in rabbit. But I'm pretty sure we'd prefer to
explode earlier if a job is asked to be started when it shouldn't.

I'd say, as per comment 4, that we could rename start() => mark_started(). But
that's out of the scope of this bug.

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to