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

fix: Don't use a reader with seeking support when no_rotate is true #18608

Merged
merged 3 commits into from
Jul 18, 2024

Conversation

erezrokah
Copy link
Member

Summary

Follow up to #18361.
When no_rotate: true we can get large files to upload and when that happens we'll be holding the whole file in memory and eventually running out of it.
An example is a sync on many AWS accounts (for example 2000), even for a single table. Let's say the table data is 10MB per account, we end up with a file of 20GB.

The downside of this change is that if a sync has a single account but many tables (and no_rotate: true), we'll run into the same issue #18361 fixed.

There are workarounds for both issues (either reducing the number of accounts in the sync, or reducing the concurrency).

The best solution would be to get aws/aws-sdk-go-v2#2694 fixed (suggested solution in https://github.com/aws/aws-sdk-go-v2/compare/main...erezrokah:fix/dont_over_allocate_small_files?expand=1), but doesn't seems like it's going to happen soon.

@erezrokah erezrokah requested a review from a team as a code owner July 18, 2024 17:22
@erezrokah erezrokah requested review from murarustefaan and removed request for a team July 18, 2024 17:22
@erezrokah erezrokah requested review from marianogappa and removed request for murarustefaan July 18, 2024 17:34
@erezrokah erezrokah requested a review from bbernays July 18, 2024 17:45
@erezrokah erezrokah added the automerge Automatically merge once required checks pass label Jul 18, 2024
@kodiakhq kodiakhq bot merged commit b5e06d3 into main Jul 18, 2024
9 checks passed
@kodiakhq kodiakhq bot deleted the fix/dont_io_readall_no_rotate branch July 18, 2024 18:29
kodiakhq bot pushed a commit that referenced this pull request Jul 19, 2024
🤖 I have created a release *beep* *boop*
---


## [7.3.1](plugins-destination-s3-v7.3.0...plugins-destination-s3-v7.3.1) (2024-07-18)


### Bug Fixes

* Don't use a reader with seeking support when `no_rotate` is true ([#18608](#18608)) ([b5e06d3](b5e06d3))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/plugin/destination/s3 automerge Automatically merge once required checks pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants