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

feat(middleware-sdk-s3): add middleware for following region redirects #5185

Merged
merged 8 commits into from
Oct 5, 2023

Conversation

siddsriv
Copy link
Contributor

@siddsriv siddsriv commented Sep 6, 2023

Issue

#1807

Description

Adds a middleware for following region redirects to support S3 global client.

Testing

Unit tests and E2E tests added and confirmed that they succeed.

E2E test:

yarn run v1.22.19
$ jest -c jest.config.e2e.js
 PASS  src/region-redirect-middleware.e2e.spec.ts (17.917 s)
  S3 Global Client Test
    ✓ Should be able to put objects following region redirect (8106 ms)
    ✓ Should be able to get objects following region redirect (1740 ms)
    ✓ Should delete objects following region redirect (876 ms)

Test Suites: 1 passed, 1 total
Tests:       3 passed, 3 total
Snapshots:   0 total
Time:        17.958 s
Ran all test suites.
Done in 18.65s.

Unit test:

yarn run v1.22.19
$ jest
 PASS  src/check-content-length-header.spec.ts
 PASS  src/validate-bucket-name.spec.ts
 PASS  src/throw-200-exceptions.spec.ts
 PASS  src/region-redirect-middleware.spec.ts

Test Suites: 4 passed, 4 total
Tests:       12 passed, 12 total
Snapshots:   0 total
Time:        4.143 s
Ran all test suites.
Done in 4.80s.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@siddsriv siddsriv requested a review from a team as a code owner September 6, 2023 17:54
@siddsriv siddsriv marked this pull request as draft September 6, 2023 17:54
@kuhe
Copy link
Contributor

kuhe commented Sep 6, 2023

  • add unit tests
  • add e2e test

@siddsriv siddsriv changed the title feat(middleware-sdk-s3): add middleware for following region redirects [DRAFT] feat(middleware-sdk-s3): add middleware for following region redirects Sep 25, 2023
@siddsriv siddsriv changed the title [DRAFT] feat(middleware-sdk-s3): add middleware for following region redirects feat(middleware-sdk-s3): add middleware for following region redirects Sep 27, 2023
@siddsriv siddsriv marked this pull request as ready for review September 27, 2023 18:11
@siddsriv siddsriv merged commit 6e139f7 into aws:main Oct 5, 2023
2 checks passed
@siddsriv siddsriv deleted the s3-global-client branch October 18, 2023 21:34
Copy link

github-actions bot commented Nov 2, 2023

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants