line |
true |
false |
branch |
34
|
0 |
0 |
unless ref $client |
37
|
0 |
0 |
unless not exists $args{'databases'} or ref $args{'databases'} eq 'ARRAY' |
51
|
0 |
0 |
if $floor |
53
|
0 |
0 |
if keys %args |
66
|
0 |
0 |
unless $client->{'verbose'} |
76
|
0 |
0 |
if ($ref->{'driver'}) { } |
78
|
0 |
0 |
if (my $getter = $ref->{'driver'}->get_dbh) { } |
90
|
0 |
0 |
unless $ref->{$_} |
103
|
0 |
0 |
if ($cache_duration and $client->{'cached_drivers'}{$hashdsn}{'create_ts'} and $client->{'cached_drivers'}{$hashdsn}{'create_ts'} + $cache_duration > $t) { } |
111
|
0 |
0 |
unless my $db = $client->{'databases'}{$hashdsn} |
114
|
0 |
0 |
if ($db->{'driver'}) { } |
124
|
0 |
0 |
if exists $db->{'prefix'} |
126
|
0 |
0 |
if ($cache_duration) |
147
|
0 |
0 |
if ($client->{'dead_dsns'}{$hashdsn}) |
148
|
0 |
0 |
if ($client->{'retry_at'}{$hashdsn} < time) { } |
166
|
0 |
0 |
unless my $job = $driver->lookup('TheSchwartz::Job', $handle->jobid) |
183
|
0 |
0 |
if exists $arg->{'run_after'} |
186
|
0 |
0 |
if exists $arg->{'grabbed_until'} |
189
|
0 |
0 |
if exists $arg->{'jobid'} |
191
|
0 |
0 |
unless exists $arg->{'funcname'} |
193
|
0 |
0 |
unless defined $arg->{'want_handle'} |
197
|
0 |
0 |
if ($arg->{'coalesce'}) |
202
|
0 |
0 |
if ($client->prioritize) { } |
212
|
0 |
0 |
if ($client->floor) |
219
|
0 |
0 |
if $client->is_database_dead($hashdsn) |
221
|
0 |
0 |
if (ref $arg->{'funcname'}) { } |
231
|
0 |
0 |
if ($arg->{'want_handle'}) { } |
269
|
0 |
0 |
if $client->is_database_dead($hashdsn) |
275
|
0 |
0 |
if ($client->prioritize) { } |
302
|
0 |
0 |
if ($client->floor) |
311
|
0 |
0 |
if ($@) |
312
|
0 |
0 |
unless ({1 => 1}->{$driver->last_error or 0}) |
318
|
0 |
0 |
if $job |
328
|
0 |
0 |
if ($client->prioritize) { } |
340
|
0 |
0 |
if $client->is_database_dead($hashdsn) |
361
|
0 |
0 |
if ($client->floor) |
370
|
0 |
0 |
if ($@) |
371
|
0 |
0 |
unless ({1 => 1}->{$driver->last_error or 0}) |
377
|
0 |
0 |
if $T_AFTER_GRAB_SELECT_BEFORE_UPDATE |
381
|
0 |
0 |
if $job |
391
|
0 |
0 |
if $driver->dbd->isa('Data::ObjectDriver::Driver::DBD::Oracle') |
416
|
0 |
0 |
unless my $server_time = $client->get_server_time($driver) |
427
|
0 |
0 |
if ($driver->update($job, {'grabbed_until', ['-and', {'op', '=', 'value', $old_grabbed_until}, \" <= $unixtime"]}) < 1) |
436
|
0 |
0 |
if $T_LOST_RACE |
479
|
0 |
0 |
if ($@) { } |
|
0 |
0 |
elsif ($job->jobid) { } |
480
|
0 |
0 |
unless ({1 => 1}->{$driver->last_error or 0}) |
509
|
0 |
0 |
if $client->is_database_dead($hashdsn) |
515
|
0 |
0 |
if ($h) { } |
524
|
0 |
0 |
if eval {
do {
$driver->commit
}
} |
529
|
0 |
0 |
wantarray ? : |
535
|
0 |
0 |
if (ref $_[0] eq 'TheSchwartz::Job') |
538
|
0 |
0 |
unless (ref $job eq 'TheSchwartz::Job') |
546
|
0 |
0 |
if $client->is_database_dead($hashdsn) |
553
|
0 |
0 |
if $handle |
590
|
0 |
0 |
if (not @{$client->{'current_abilities'};}) |
598
|
0 |
0 |
unless my $job = $client->lookup_job($hstr) |
606
|
0 |
0 |
unless my $job = $client->lookup_job($hstr) |
613
|
0 |
0 |
if $current_time < $job->grabbed_until |
616
|
0 |
0 |
unless $job = $client->_grab_a_job($hashdsn, $job) |
627
|
0 |
0 |
unless $client->work_once |
634
|
0 |
0 |
unless $client->work_once |
650
|
0 |
0 |
if (not $job || $client->{'strict_remove_ability'} and @{$client->{'current_abilities'};} < @{$client->{'all_abilities'};}) |
658
|
0 |
0 |
$job ? : |
659
|
0 |
0 |
if ($job) { } |
660
|
0 |
0 |
$job->priority ? : |
669
|
0 |
0 |
unless $job |
676
|
0 |
0 |
unless $client->{'strict_remove_ability'} |
696
|
0 |
0 |
unless (exists $cache->{'funcname2id'}{$funcname}) |
707
|
0 |
0 |
unless (exists $client->{'funcmap_cache'}{$hashdsn}) |
730
|
0 |
0 |
if ($logger and ref $logger ne 'CODE') |
750
|
0 |
0 |
unless $dir |
753
|
0 |
0 |
if ($dir eq '1' or $dir eq 'on') |
758
|
0 |
0 |
if -e $dir |
763
|
0 |
0 |
unless (-e $dir) |
764
|
0 |
0 |
unless mkdir $dir, 493 |
776
|
0 |
0 |
unless $scoreboard |
780
|
0 |
0 |
unless $job |
784
|
0 |
0 |
unless open my $SB, '>', $scoreboard |
805
|
0 |
0 |
if (ref $args) { } |
806
|
0 |
0 |
if (ref $args eq 'HASH') { } |
|
0 |
0 |
elsif (ref $args eq 'ARRAY') { } |
826
|
0 |
0 |
unless $scoreboard |
830
|
0 |
0 |
unless open my $SB, '>>', $scoreboard |
843
|
0 |
0 |
unless $scoreboard |
865
|
0 |
0 |
unless $client->prioritize |
905
|
0 |
0 |
if (ref $arg and $arg->isa('TheSchwartz')) |