From 7a5fcb4bb17067f373270f27fc14677866ba8f8f Mon Sep 17 00:00:00 2001 From: Qi Date: Wed, 18 Oct 2023 11:37:04 +0800 Subject: [PATCH 1/3] chore(CI): do not run tests if only docs were changed --- .github/workflows/build_and_test.yml | 1 + .github/workflows/release.yml | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 2e044c2dc42b..ae7a234da9cc 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -6,6 +6,7 @@ on: - '**/*.md' - '.github/workflows/release.yml' - 'changelog/**' + - 'kong.conf.default' push: paths-ignore: # ignore markdown files (CHANGELOG.md, README.md, etc.) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 23f100633ebb..6aaae1c33bf0 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -4,6 +4,11 @@ name: Package & Release on: # yamllint disable-line rule:truthy pull_request: + paths-ignore: + - '**/*.md' + - '.github/workflows/build_and_test.yml' + - 'changelog/**' + - 'kong.conf.default' schedule: - cron: '0 0 * * *' push: From 11911a4ea4afd30cf56cedc8c49291ddf1442d91 Mon Sep 17 00:00:00 2001 From: Qi Date: Wed, 18 Oct 2023 11:28:26 +0800 Subject: [PATCH 2/3] docs(request-debugging): add docs to `kong.conf.default` Co-authored-by: Datong Sun --- kong.conf.default | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/kong.conf.default b/kong.conf.default index 1d288e795e89..06839d81ec6c 100644 --- a/kong.conf.default +++ b/kong.conf.default @@ -2105,3 +2105,49 @@ # - `resolver_add` # - `proxy_wasm_request_headers_in_access` # - `shm_queue` + +#------------------------------------------------------------------------------- +# REQUEST DEBUGGING +#------------------------------------------------------------------------------- +# Request debugging is a mechanism that allows admin to reveal the timing of +# proxy path request in the response header (X-Kong-Request-Debug-Output) +# and optionally, the error log. +# +# This feature provides insights into the time spent within various components of Kong, +# such as plugins, DNS resolution, load balancing, and more. It also provides contextual +# information such as domain name tried during these processes. +# +#request_debug = on # When enabled, Kong will provide detailed timing information + # for its components to the client and the error log + # if the following headers are present in the proxy request: + # - `X-Kong-Request-Debug`: + # If the value is set to `*`, + # timing information will be collected and exported for the current request. + # If this header is not present or contains unknown value + # timing information will not be collected for the current request. + # + # - `X-Kong-Request-Debug-Log`: + # If set to `true`, timing information will also be logged + # in the Kong error log with a log level of `notice`. + # Defaults to `false`. + # + # - `X-Kong-Request-Debug-Token`: + # Token for authenticating the client making the debug + # request to prevent abuse. Debug requests originating from loopback + # addresses do not require this header. + # +#request_debug_token = # The Request Debug Token is used in the + # `X-Kong-Request-Debug-Token` header to prevent abuse. + # If this value is not set (the default), + # a random token will be generated + # when Kong starts, restarts, or reloads. + # + # You can locate the generated debug token in two locations: + # - Kong error log: + # Debug token will be logged in the error log (notice level) + # when Kong starts, restarts, or reloads. + # The log line will have the: `[request-debug]` prefix to aid searching. + # - Filesystem: + # Debug token will also be stored in a file located at + # `{prefix}/.request_debug_token` and updated + # when Kong starts, restarts, or reloads. From 1864f8f4ce5d734120b957d703f3799adf232861 Mon Sep 17 00:00:00 2001 From: Datong Sun Date: Wed, 18 Oct 2023 18:05:24 +0800 Subject: [PATCH 3/3] Update kong.conf.default --- kong.conf.default | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/kong.conf.default b/kong.conf.default index 06839d81ec6c..a99ca54d83e2 100644 --- a/kong.conf.default +++ b/kong.conf.default @@ -2109,7 +2109,7 @@ #------------------------------------------------------------------------------- # REQUEST DEBUGGING #------------------------------------------------------------------------------- -# Request debugging is a mechanism that allows admin to reveal the timing of +# Request debugging is a mechanism that allows admin to collect the timing of # proxy path request in the response header (X-Kong-Request-Debug-Output) # and optionally, the error log. # @@ -2123,7 +2123,7 @@ # - `X-Kong-Request-Debug`: # If the value is set to `*`, # timing information will be collected and exported for the current request. - # If this header is not present or contains unknown value + # If this header is not present or contains unknown value, # timing information will not be collected for the current request. # # - `X-Kong-Request-Debug-Log`: @@ -2140,7 +2140,8 @@ # `X-Kong-Request-Debug-Token` header to prevent abuse. # If this value is not set (the default), # a random token will be generated - # when Kong starts, restarts, or reloads. + # when Kong starts, restarts, or reloads. If a token is + # specified manually, then the provided token will be used. # # You can locate the generated debug token in two locations: # - Kong error log: