Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Construct HTTP log message only if needed #165057

Merged

Conversation

danielmitterdorfer
Copy link
Member

Summary

Previously we have unconditionally created a debug log message that potentially involved serializing a large response object only to ignore it if the the log level 'debug' is disabled for that logger. With this commit we add a check if the respective level is enabled on the logger before we proceed to construct the log message.

For maintainers

Previously we have unconditionally created a debug log message that
potentially involved serializing a large response object only to ignore
it if the the log level 'debug' is disabled for that logger. With this
commit we add a check if the respective level is enabled on the logger
before we proceed to construct the log message.
@danielmitterdorfer danielmitterdorfer added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting v8.11.0 labels Aug 29, 2023
@danielmitterdorfer danielmitterdorfer requested a review from a team as a code owner August 29, 2023 06:52
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@apmmachine
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • /oblt-deploy-serverless : Deploy a serverless Kibana instance using the Observability test environments.
  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

Copy link
Member

@afharo afharo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this! LGTM!

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

✅ unchanged

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@danielmitterdorfer danielmitterdorfer merged commit aa27425 into elastic:main Aug 29, 2023
@danielmitterdorfer danielmitterdorfer deleted the guard-response-log branch August 29, 2023 08:15
@danielmitterdorfer
Copy link
Member Author

Thanks for the quick review!

jloleysens added a commit to jloleysens/kibana that referenced this pull request Aug 29, 2023
* main: (40 commits)
  Adjust migrations and elasticsearch service settings for serverless. (elastic#165050)
  [Security Solution] expandable flyout - add investigate in timeline f… (elastic#165025)
  [SecuritySolution] Hide create dashboard button from listing (elastic#164476)
  Construct HTTP log message only if needed (elastic#165057)
  [Security Solution] expandable flyout - add no data message in entities details and entities overview components (elastic#164955)
  Add functional tests for serverless security management UIs (elastic#164886)
  [api-docs] 2023-08-29 Daily api_docs build (elastic#165056)
  [Cloud Security][CIS GCP]cis gcp now use updated gcp field name + small last minute changes (elastic#164792)
  [Security Solution] Expandable flyout - update risk classification ui in entities overview (elastic#165022)
  [Security Solution] Fixes Preconfigured Connectors not working with Assistant (elastic#164900)
  [Security Solution] Coverage Overview follow-up 2 (elastic#164986)
  [DOCS] Add cross-link for other encryption key settings (elastic#165014)
  chore(slo): general enhancement (elastic#164723)
  Revert "[SOR] Allow optionally downgrading documents with a higher version model in API READ methods" (elastic#164991)
  [OAS] Add more Elasticsearch query rule examples (elastic#164386)
  [security_solution_cypress] Add support for options in EsArchiver.load (elastic#164988)
  [Event Log] Skip setting assets to hidden in serverless (elastic#164767)
  remove unneeded usages of isErrorResponse (elastic#164609)
  [Enterprise Search] Make network drive connector platinum (elastic#165007)
  [RAM] update api key to become public (elastic#164883)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v8.11.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants