Hook up the retryable tasks with hydra-notify
This commit is contained in:
@ -6,6 +6,7 @@ use utf8;
|
||||
use base 'DBIx::Class::ResultSet';
|
||||
use List::Util qw(max);
|
||||
use Hydra::Math qw(exponential_backoff);
|
||||
use Hydra::Task;
|
||||
|
||||
=head2 get_seconds_to_next_retry
|
||||
|
||||
|
@ -254,7 +254,7 @@ sub failure {
|
||||
my $event_labels = $self->prom_labels_for_task($task);
|
||||
|
||||
if (defined($task->{"record"})) {
|
||||
if ($task->{"record"}->{"attempts"} > 100) {
|
||||
if ($task->{"record"}->attempts > 100) {
|
||||
$self->{"prometheus"}->inc("notify_plugin_drop", $event_labels);
|
||||
$task->{"record"}->delete();
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user