log request id mappings from cinder

Registered by Abhijeet Malawade

Each OpenStack service sends a request ID header with HTTP responses. This value can be useful for tracking down problems in the logs.
However, when operations cross service boundaries (i.e.- trove gives call to cinder), this tracking can become difficult, as each service has its own request ID. This becomes especially problematic when requests are coming in parallel.

By logging a mapping of trove's request ID and cinder's request ID on the same log line, the user can easily find the cinder request ID that is related to trove request in the trove service logs. That cinder request ID can then be searched in cinder's logs. It will help operators/developers to analyse logs effectively.

Currently cinder-client is not returning response header back to the caller, it is just returning response body. Work is in progress [1] to return response headers (and body in tuple) from cinder-client. Cinder-client will return tuple containing header and body,
when this 'return request id' feature gets merged. We can get 'request-id' of cinder from response headers returned by cinder-client.

If trove tries to use new version of cinder-client returning tuple, then it will fail. Because it is expecting only body, but new cinder-client will return tuple containing header and body. So we need to add support to check type of response returned by cinder-client in trove.
Also we need this cinder-client return format type checking for backward compatibility.

[1] https://review.openstack.org/#/c/132161/ (cinder spec to return request id)

Blueprint information

Status:
Not started
Approver:
None
Priority:
Undefined
Drafter:
Abhijeet Malawade
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Related branches

Sprints

Whiteboard

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.

Subscribers

No subscribers.