opensearch-project / opensearch-project/data-prepper
[BUG] Sigv4 error when hosts has "/ " at the end of URL
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 374
- Forks
- 354
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 8
Description
Describe the bug
Data Prepper is throwing Sigv4 error when OpenSearch URL in hosts has "/ " at the end of URL
To Reproduce
Steps to reproduce the behavior:
- Go to pipeline.yaml
- Click on Sinks
- under OpenSearch - hosts give / at the end of URL say - "https://mydomain-us-east-1.es.amazonaws.com/" -- This URL works fine "https://mydomain-us-east-1.es.amazonaws.com"
- See error
Caused by: 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.
Expected behavior
Connection to OpenSearch should be successful with or with of "/" at the end of URL
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with pipeline.yaml and the OpenSearch sink configuration, then trace how the hosts value reaches SigV4 request signing. Reproduce the failure with a trailing slash and verify that both URL forms connect successfully, adding a regression test if the existing test structure is identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, java
- Domain
- authentication, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100