[BUG] The deprecation message of `DeprecatedRoute` doesn't show in the API response
See original GitHub issueDescribe the bug
The deprecation message of DeprecatedRoute
doesn’t show in the API response
To Reproduce Steps to reproduce the behavior:
- Checkout the branch
- Check the DeprecatedRoute. Wait for a couple of seconds to allow the page to be redirected to the highlighted lines.
This is the same approach using
DeprecatedRoute
as here. - Build security plugin:
./gradlew clean build -Dbuild.snapshot=false -x test
- Get the security plugin zip file from
build/distribution
folder. - Install security plugin on OpenSearch 2.0
- Log into OpenSearch node and go to the folder
opensearch/config
- Send the whitelist API request with super admin certs.
curl -k -i --cert kirk.pem --key kirk-key.pem https://localhost:9200/_plugins/_security/api/whitelist\?pretty -u admin:admin --insecure
Expected response
The deprecation message("[/whitelist] is a deprecated endpoint. Please use [/allowlist] instead."
) should show in the response
Actual response The deprecation message doesn’t show in the response or the logs.
HTTP/1.1 200 OK
content-type: application/json; charset=UTF-8
content-length: 171
{
"config" : {
"enabled" : false,
"requests" : {
"/_cluster/settings" : [
"GET"
],
"/_cat/nodes" : [
"GET"
]
}
}
}
Plugins Security plugin
Issue Analytics
- State:
- Created a year ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Convention for HTTP response header to notify clients of ...
The problem with 410 is that it does not match the "to-be-deprecated" requirement... It works fine when the API is gone, but not...
Read more >Deprecating API Endpoints - Stoplight Blog
Deprecation communicates a function, method, or entire package is going away or being. How do you warn developers when an API or endpoint...
Read more >Important changes (deprecations) coming in Power Apps and ...
"Deprecated" means we intend to remove the feature or capability from a future release. The feature or capability will continue to work and...
Read more >Deprecations · Cloudflare Workers docs
This field is not mandatory, and defaults to true when route or routes are not configured. When routes are present, it defaults to...
Read more >Deprecations by version - GitLab Docs
x.x will display a deprecation warning in the pipeline's Security tab. ... in the deprecated versions because we do not backport bugs and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@cliu123 you should be able to get
Warning
header by by addingto
config/log4j2.properties
.The expected behavior has been clarified! Thanks @tlfeng @reta! Closing the issue.