From 7273146d1a0db7a911fad443138217f20310ba71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Humberto=20Corr=C3=AAa=20da=20Silva?= Date: Wed, 5 Oct 2022 16:47:54 -0300 Subject: [PATCH] Add documentation about decision log req_id attribute MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The documentation purpose is to explain the relation with others logs, how it could be used, and when it is included on decision logs. Fixes: #5006 Signed-off-by: Humberto CorrĂȘa da Silva --- docs/content/management-decision-logs.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/content/management-decision-logs.md b/docs/content/management-decision-logs.md index c1d90859d7..9917239b9a 100644 --- a/docs/content/management-decision-logs.md +++ b/docs/content/management-decision-logs.md @@ -76,6 +76,7 @@ Decision log updates contain the following fields: | `[_].erased` | `array[string]` | Set of JSON Pointers specifying fields in the event that were erased. | | `[_].masked` | `array[string]` | Set of JSON Pointers specifying fields in the event that were masked. | | `[_].nd_builtin_cache` | `object` | Key-value pairs of non-deterministic builtin names, paired with objects specifying the input/output mappings for each unique invocation of that builtin during policy evaluation. Intended for use in debugging and decision replay. Receivers will need to decode the JSON using Rego's JSON decoders. | +| `[_].req_id` | `number` | Unique request identifier for the request that started the policy query. The attribute value is the same as the value present in others logs (request, response, and print) and could be used to correlate them all. This attribute will be included just when OPA runtime is initialized in server mode and the log level is equal or greater than info. | If the decision log was successfully uploaded to the remote service, it should respond with an HTTP 2xx status. If the service responds with a non-2xx status, OPA will requeue the last chunk containing decision log events and upload it