Make Trove exists events notifs be emitted in current audit period
Following the guidelines in https://wiki.openstack.org/wiki/NotificationEventExamples, we should make sure that the exists notifications are emitted with a current audit period instead of the future audit period we are currently using. Change-Id: I4e19d47ec8827709dbd4b22569877ef2c7c9ea77 Closes-Bug: #1469860
This commit is contained in:
parent
ed9609f1f4
commit
4d5e887140
|
@ -188,11 +188,11 @@ class NotificationTransformer(object):
|
|||
@staticmethod
|
||||
def _get_audit_period():
|
||||
now = datetime.datetime.now()
|
||||
audit_start = utils.isotime(now, subsecond=True)
|
||||
audit_end = utils.isotime(
|
||||
now + datetime.timedelta(
|
||||
audit_start = utils.isotime(
|
||||
now - datetime.timedelta(
|
||||
seconds=CONF.exists_notification_interval),
|
||||
subsecond=True)
|
||||
audit_end = utils.isotime(now, subsecond=True)
|
||||
return audit_start, audit_end
|
||||
|
||||
def _get_service_id(self, datastore_manager, id_map):
|
||||
|
|
Loading…
Reference in New Issue