diff options
author | Sean Dague <sean@dague.net> | 2017-05-14 07:14:25 -0400 |
---|---|---|
committer | Sean Dague <sean@dague.net> | 2017-05-23 10:22:34 -0400 |
commit | ec7cdc4cc560150673f14c84a326f6a72d43d3e1 (patch) | |
tree | fa536aaad817159eb090f8823863be5c3fc72883 /doc | |
parent | 68b0476999cb240a450e3cb6289e1eb9caa7b063 (diff) | |
download | oslo-context-ec7cdc4cc560150673f14c84a326f6a72d43d3e1.tar.gz |
Add global_request_id to context
This provides the facility to have a global_request_id which is
different from the service level request_id that we've been using.
Includes basic testing.
Change-Id: I1521188ae627fa2e7d35aa2ffffbcb620c527765
Diffstat (limited to 'doc')
-rw-r--r-- | doc/source/usage.rst | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/doc/source/usage.rst b/doc/source/usage.rst index 8c84163..6674613 100644 --- a/doc/source/usage.rst +++ b/doc/source/usage.rst @@ -26,8 +26,8 @@ Source: :ref:`example_usage_simple.py` 2016-01-20 21:56:29.283 8428 INFO __main__ [-] Message without context 2016-01-20 21:56:29.284 8428 INFO __main__ [req-929d23e9-f50e-46ae-a8a7-02bc8c3fd2c8 - - - - -] Message with context -The format of these log records are defined by the -`logging_default_format_string`_ and `logging_context_format_string`_ +The format of these log records are defined by the +`logging_default_format_string`_ and `logging_context_format_string`_ configuration options respectively. The `logging_user_identity_format`_ option also provides further context aware definition flexibility. @@ -39,9 +39,12 @@ also provides further context aware definition flexibility. Context Variables ----------------- -The oslo.context variables used in the **logging_context_format_string** and +The oslo.context variables used in the **logging_context_format_string** and **logging_user_identity_format** configuration options include: +* global_request_id - A request id + (e.g. req-9f2c484a-b504-4fd9-b44c-4357544cca50) which may have been + sent in from another service to indicate this is part of a chain of requests. * request_id - A request id (e.g. req-9f2c484a-b504-4fd9-b44c-4357544cca50) * user - A user id (e.g. e5bc7033e6b7473c9fe8ee1bd4df79a3) * tenant - A tenant/project id (e.g. 79e338475db84f7c91ee4e86b79b34c1) |