Skip to content

Commit

Permalink
docs(object-store): add warning to flush (#5369)
Browse files Browse the repository at this point in the history
* add warning to flush

* Update object_store/src/lib.rs

Co-authored-by: Raphael Taylor-Davies <1781103+tustvold@users.noreply.github.com>

* format

---------

Co-authored-by: Raphael Taylor-Davies <1781103+tustvold@users.noreply.github.com>
  • Loading branch information
wjones127 and tustvold authored Feb 7, 2024
1 parent ae85263 commit 5572398
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions object_store/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -551,6 +551,15 @@ pub trait ObjectStore: std::fmt::Display + Send + Sync + Debug + 'static {
/// writer fails or panics, you must call [ObjectStore::abort_multipart]
/// to clean up partially written data.
///
/// <div class="warning">
/// It is recommended applications wait for any in-flight requests to complete by calling `flush`, if
/// there may be a significant gap in time (> ~30s) before the next write.
/// These gaps can include times where the function returns control to the
/// caller while keeping the writer open. If `flush` is not called, futures
/// for in-flight requests may be left unpolled long enough for the requests
/// to time out, causing the write to fail.
/// </div>
///
/// For applications requiring fine-grained control of multipart uploads
/// see [`MultiPartStore`], although note that this interface cannot be
/// supported by all [`ObjectStore`] backends.
Expand Down

0 comments on commit 5572398

Please sign in to comment.