Open mschmie opened 10 months ago
Hello,
any updates or hints about this issue ? We have got the same issue when using Opensearch in AWS
Best regards,
AFAIK nobody is working on this. Want to help?
curl
against the Amazon managed service and serverless, https://code.dblock.org/2022/07/11/making-sigv4-authenticated-requests-to-managed-opensearch.html can help.Is this a dup of https://github.com/opensearch-project/opensearch-java/issues/521? There's a failing integration test in https://github.com/opensearch-project/opensearch-java/issues/712 if you want to fix this and include it.
Replacing ApacheHttpClient
by NettyNioAsyncHttpClient
solves the issue.
cf https://github.com/opensearch-project/data-prepper/pull/3338
What is the bug?
clearScroll
request to opensearch client fails with sigv4 signing mismatch:org.opensearch.client.opensearch._types.OpenSearchException: Request failed: [security_exception] The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.
The Canonical String for this request should have been 'DELETE /_search/scroll
... remaining request info...
How can one reproduce the bug?
How can one reproduce the bug?
Create an OpenSearchClient following instructions from here (https://opensearch.org/docs/2.7/clients/java/#connecting-to-amazon-opensearch-service) and then attempt to use the client's
clearScroll
API.I believe this is because it is a DELETE request with a body. The
search/scroll
method works as intended. Sending the request results in a sigv4 errorWhat is the expected behavior?
The
clearScroll
API call does not have a signature mismatchWhat is your host/environment?
Ubuntu 22.04
implementation 'org.opensearch.client:opensearch-java:2.8.0'
Do you have any screenshots?
If applicable, add screenshots to help explain your problem.
Do you have any additional context?
Add any other context about the problem.