Merge pull request #2209 from coreos-inc/clair-notification-read

Clair notification read and queue fixes
This commit is contained in:
Jimmy Zelinskie 2016-12-05 19:36:59 -05:00 committed by GitHub
commit 3a7119d499
4 changed files with 55 additions and 8 deletions

View file

@ -37,8 +37,11 @@ class SecurityNotificationWorker(QueueWorker):
if should_retry:
raise JobException()
else:
# Return to mark the job as "complete", as we'll never be able to finish it.
# Remove the job from the API.
logger.error('Failed to handle security notification %s', notification_name)
secscan_api.mark_notification_read(notification_name)
# Return to mark the job as "complete", as we'll never be able to finish it.
return False
self.extend_processing(_PROCESSING_SECONDS, json.dumps(data))