From: Samuel Matzek Date: Wed, 18 Nov 2015 19:40:42 +0000 (-0600) Subject: Preserve request id in Cinder logs X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=2cf1f17ee5dc4957efbbc1f1f8f3781d7b9408d5;p=openstack-build%2Fcinder-build.git Preserve request id in Cinder logs Several Cinder volume drivers make calls to get the admin context. When the admin context is retrieved the user context and its request ID is lost and all subsequent log entries have different request IDs. The fix is to pass the overwrite parameter in Cinder's RequestContext __init__ method to the parent oslo class. Partial-Bug: #1511406 Change-Id: I8972b46f15518f22dc9bb340d7c1ba08be1fa2bc --- diff --git a/cinder/context.py b/cinder/context.py index 8c43d9884..e2f627971 100644 --- a/cinder/context.py +++ b/cinder/context.py @@ -75,7 +75,8 @@ class RequestContext(context.RequestContext): user_domain=user_domain, project_domain=project_domain, is_admin=is_admin, - request_id=request_id) + request_id=request_id, + overwrite=overwrite) self.roles = roles or [] self.project_name = project_name self.read_deleted = read_deleted