Merge pull request #2777 from coreos-inc/joseph.schorr/QUAY-618/notificationworker-data-interface
Change notificationworker to use data interface
This commit is contained in:
commit
fdb21aa5dc
13 changed files with 167 additions and 87 deletions
|
@ -125,10 +125,12 @@ def delete_matching_notifications(target, kind_name, **kwargs):
|
|||
notification.delete_instance()
|
||||
|
||||
|
||||
def increment_notification_failure_count(notification_id):
|
||||
def increment_notification_failure_count(uuid):
|
||||
""" This increments the number of failures by one """
|
||||
RepositoryNotification.update(number_of_failures=RepositoryNotification.number_of_failures + 1).where(
|
||||
RepositoryNotification.id == notification_id).execute()
|
||||
(RepositoryNotification
|
||||
.update(number_of_failures=RepositoryNotification.number_of_failures + 1)
|
||||
.where(RepositoryNotification.uuid == uuid)
|
||||
.execute())
|
||||
|
||||
|
||||
def reset_notification_number_of_failures(namespace_name, repository_name, uuid):
|
||||
|
|
Reference in a new issue