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

PoC to buffer write requests #854

Closed
wants to merge 1 commit into from
Closed

PoC to buffer write requests #854

wants to merge 1 commit into from

Conversation

passaro
Copy link
Contributor

@passaro passaro commented Apr 16, 2024

Buffer write requests into part-size buffers before sending them to the CRT client.

Draft: it will need some tidy up and fixing test failures (cancellation/error reporting).


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license and I agree to the terms of the Developer Certificate of Origin (DCO).

Signed-off-by: Alessandro Passaro <[email protected]>
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro had a problem deploying to PR integration tests April 16, 2024 10:07 — with GitHub Actions Failure
@passaro passaro added the performance PRs to run benchmarks on label Apr 16, 2024
@@ -11,6 +11,7 @@ description = "High-performance Amazon S3 client for Mountpoint for Amazon S3."
mountpoint-s3-crt = { path = "../mountpoint-s3-crt", version = "0.7.0" }
mountpoint-s3-crt-sys = { path = "../mountpoint-s3-crt-sys", version = "0.7.0" }

async-channel = "2.1.1"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the channel provided by tokio (which we already have a dep on) useful here?

https://docs.rs/tokio/latest/tokio/sync/mpsc/index.html

.write(slice, false)
.await
.map_err(S3RequestError::CrtError)?;
// Send data to the write queue.
Copy link
Contributor

@vladem vladem Apr 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the backpressure is not implemented in any form with this change, right? was it the same before switching to async write API?

By not having backpressure I mean that write() syscalls complete as soon as they've buffered data in RAM, user application has no way of finding out that S3 requests do not adjust to their writing speed and the buffer just keeps growing. This is the behaviour now and before the async write API?

@passaro
Copy link
Contributor Author

passaro commented May 10, 2024

Dropping in favor of #874.

@passaro passaro closed this May 10, 2024
@passaro passaro deleted the buffer branch May 13, 2024 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance PRs to run benchmarks on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants