diff options
author | Trinity Pointard <trinity.pointard@gmail.com> | 2021-03-26 22:32:09 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2021-04-27 16:37:10 +0200 |
commit | 1e3df189d0dc37880219338c53607152ae0c87e0 (patch) | |
tree | db1a0ccea1b29c8916ed3246ff71ea66b3323bac /src/api/s3_get.rs | |
parent | a2e1617d845e72c44b07f782801549f209ce14cc (diff) | |
download | garage-1e3df189d0dc37880219338c53607152ae0c87e0.tar.gz garage-1e3df189d0dc37880219338c53607152ae0c87e0.zip |
document api crate
Diffstat (limited to 'src/api/s3_get.rs')
-rw-r--r-- | src/api/s3_get.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/api/s3_get.rs b/src/api/s3_get.rs index 2590c9bd..15c0ed0a 100644 --- a/src/api/s3_get.rs +++ b/src/api/s3_get.rs @@ -1,3 +1,4 @@ +//! Function related to GET and HEAD requests use std::sync::Arc; use std::time::{Duration, UNIX_EPOCH}; @@ -79,6 +80,7 @@ fn try_answer_cached( } } +/// Handle HEAD request pub async fn handle_head( garage: Arc<Garage>, req: &Request<Body>, @@ -118,6 +120,7 @@ pub async fn handle_head( Ok(response) } +/// Handle GET request pub async fn handle_get( garage: Arc<Garage>, req: &Request<Body>, @@ -224,7 +227,7 @@ pub async fn handle_get( } } -pub async fn handle_get_range( +async fn handle_get_range( garage: Arc<Garage>, version: &ObjectVersion, version_data: &ObjectVersionData, |