K2V PollRange, version 2 #471

Merged
lx merged 18 commits from k2v-watch-range-2 into main 2023-01-26 16:19:05 +00:00
2 changed files with 2 additions and 2 deletions
Showing only changes of commit cbfae673e8 - Show all commits

View file

@ -256,7 +256,7 @@ pub(crate) async fn handle_poll_range(
let query = parse_json_body::<PollRangeQuery>(req).await?; let query = parse_json_body::<PollRangeQuery>(req).await?;
let timeout_msec = query.timeout.unwrap_or(300).clamp(10, 600) * 1000; let timeout_msec = query.timeout.unwrap_or(300).clamp(1, 600) * 1000;
let resp = garage let resp = garage
.k2v .k2v

View file

@ -206,7 +206,7 @@ pub async fn handle_poll_item(
let causal_context = let causal_context =
CausalContext::parse(&causality_token).ok_or_bad_request("Invalid causality token")?; CausalContext::parse(&causality_token).ok_or_bad_request("Invalid causality token")?;
let timeout_msec = timeout_secs.unwrap_or(300).clamp(10, 600) * 1000; let timeout_msec = timeout_secs.unwrap_or(300).clamp(1, 600) * 1000;
let item = garage let item = garage
.k2v .k2v