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

Backport PR #15640 to 8.11: Added missing method of logger wrapper for puma #15642

Merged
merged 1 commit into from Nov 30, 2023

Conversation

github-actions[bot]
Copy link
Contributor

Backport PR #15640 to 8.11 branch, original message:


Release notes

Fix node stats API when the API path is invalid

What does this PR do?

The PR adds the missing method debug? in DelegatingLogWriter

Puma uses stderr to log error. DelegatingLogWriter takes IOWrappedLogger as stderr and IOWrappedLogger takes DelegatingLogWriter as logger. IOWrappedLogger checks logger level here.

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

The change allow node state to return meaningful error message

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

Run this branch and curl -XGET 'localhost:9600/_node/stats/invalid_path'. The response should not throw exception.

Related issues

Use cases

Screenshots

Logs

This commit fixes no method error when node stats API got
invalid API path, which triggers puma to print error using stderr

Fix: #15639
(cherry picked from commit 05392ad)
Copy link

SonarQube Quality Gate

Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

@kaisecheng kaisecheng merged commit 6d55f26 into 8.11 Nov 30, 2023
5 checks passed
@jsvd jsvd deleted the backport_15640_8.11 branch March 11, 2024 09:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants