diff --git a/lambdas/indexer/app.py b/lambdas/indexer/app.py index 3445cd9fbe..4bdd8caab2 100644 --- a/lambdas/indexer/app.py +++ b/lambdas/indexer/app.py @@ -95,9 +95,11 @@ def log_forwarder(self, prefix: str): s3_decorator = self.on_s3_event(bucket=aws.logs_bucket, events=['s3:ObjectCreated:*'], prefix=prefix) - error_decorator = app.metric_alarm(metric=LambdaMetric.errors) + error_decorator = app.metric_alarm(metric=LambdaMetric.errors, + threshold=1, # One alarm … + period=24 * 60 * 60) # … per day. throttle_decorator = app.metric_alarm(metric=LambdaMetric.throttles) - retry_decorator = app.retry(times=0) + retry_decorator = app.retry(times=2) def decorator(f): return throttle_decorator(error_decorator(retry_decorator(s3_decorator(f))))