using utcnow instead of now in expiration policy

Change-Id: I69b507cd9d9d18dcf589d2a832ed4619ee69d09e
Closes-bug: #1657368
This commit is contained in:
Kupai József 2017-01-17 15:49:15 +01:00
parent e037e9bf8f
commit fb384c9aba

View File

@ -61,7 +61,7 @@ def run_execution_expiration_policy(self, ctx):
LOG.debug("Starting expiration policy task.")
older_than = CONF.execution_expiration_policy.older_than
exp_time = (datetime.datetime.now()
exp_time = (datetime.datetime.utcnow()
- datetime.timedelta(minutes=older_than))
with db_api.transaction():