projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
PREVIEWED als Übersetzung in Kommentar, damit diese erhalten bleibt …
[kivitendo-erp.git]
/
SL
/
BackgroundJob
/
Test.pm
diff --git
a/SL/BackgroundJob/Test.pm
b/SL/BackgroundJob/Test.pm
index
01c8569
..
a70b7a3
100644
(file)
--- a/
SL/BackgroundJob/Test.pm
+++ b/
SL/BackgroundJob/Test.pm
@@
-1,13
+1,20
@@
package SL::BackgroundJob::Test;
package SL::BackgroundJob::Test;
+use strict;
+
use parent qw(SL::BackgroundJob::Base);
use parent qw(SL::BackgroundJob::Base);
+use SL::System::TaskServer;
+
sub run {
sub run {
- my
$self = shift
;
- my $d
b_obj = shift
;
+ my
($self, $db_obj) = @_
;
+ my $d
ata = $db_obj->data_as_hash
;
- $::lxdebug->message(0, "Test job is being executed.");
-}
+ $::lxdebug->message(0, "Test job ID " . $db_obj->id . " is being executed on node " . SL::System::TaskServer::node_id() . ".");
+ die "Oh cruel world: " . $data->{exception} if $data->{exception};
+
+ return exists $data->{result} ? $data->{result} : 1;
+}
1;
1;