Fix the metrics so they are usable for scaling the workers down and up. Switch all datetimes which touch the database from now to utcnow. Fix the worker Dockerfile.
This commit is contained in:
parent
f4c488f9b6
commit
0b6552d6cc
10 changed files with 137 additions and 75 deletions
|
@ -41,7 +41,7 @@ def _validate_and_apply_oauth_token(token):
|
|||
}
|
||||
abort(401, message='OAuth access token could not be validated: %(token)s',
|
||||
issue='invalid-oauth-token', token=token, headers=authenticate_header)
|
||||
elif validated.expires_at <= datetime.now():
|
||||
elif validated.expires_at <= datetime.utcnow():
|
||||
logger.info('OAuth access with an expired token: %s', token)
|
||||
authenticate_header = {
|
||||
'WWW-Authenticate': ('Bearer error="invalid_token", '
|
||||
|
|
Reference in a new issue