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

Ensure plugin config marked :deprecated logs to deprecation logger #16863

Merged
merged 2 commits into from
Jan 7, 2025

Conversation

donoghuc
Copy link
Member

@donoghuc donoghuc commented Jan 6, 2025

Release notes

Log messages for configuration options marked as :deprecated in plugin config are now routed to the deprecation logger in addition to the main logger. In the next major version (9.0.0) these messages will only go to the deprecation logger.

What does this PR do?

Ensure plugin config marked :deprecated logs to deprecation logger
Previously when the :deprecated modifier was used in the plugin config DSL a
log message was sent at :warn level ONLY to the main logger. This commit updates
that message to be routed both to the deprecation logger as well as the main
logger. In 9.x this will only go to the deprecation logger.

Why is it important/What is the impact to the user?

Instead of needing to check the main logger for deprecation messages logged at WARN level, users can now expect to find the messages at the expected deprecation logger location. This allows them to find the complete set in the designated/expected destination. Note that the WARN message destined for the main logger is preserved in 8.x but in 9.x the message will only go to the deprecation logger.

Checklist

  • My code follows the style guidelines of this project
  • [ ] I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have made corresponding change to the default configuration files (and/or docker env variables)
  • I have added tests that prove my fix is effective or that my feature works

Author's Checklist

  • [ ]

How to test this PR locally

Related issues

Closes #14988

…lastic#16833)

Previously when the `:deprecated` modifier was used in the plugin config DSL a
log message was sent at `:warn` level to the main logger. This commit updates
that message to be routed *only* to the deprecation logger.
Previously when the `:deprecated` modifier was used in the plugin config DSL a
log message was sent at `:warn` level ONLY to the main logger. This commit updates
that message to be routed *both* to the deprecation logger as well as the main
logger. In 9.x this will *only* go to the deprecation logger.
Copy link
Contributor

@mashhurs mashhurs left a comment

Choose a reason for hiding this comment

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

LGTM on 🟢 CI!

Copy link

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

@donoghuc donoghuc merged commit 0ac587e into elastic:8.x Jan 7, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants