WIP checks

This commit is contained in:
Dominik Werder
2023-04-05 12:00:18 +02:00
parent 7c9085fe5b
commit 81298b16df
39 changed files with 892 additions and 308 deletions

View File

@@ -96,12 +96,12 @@ impl BinnedQuery {
pub fn timeout_value(&self) -> Duration {
match &self.timeout {
Some(x) => x.clone(),
None => Duration::from_millis(10000),
None => Duration::from_millis(6000),
}
}
pub fn bins_max(&self) -> u32 {
self.bins_max.unwrap_or(1024)
self.bins_max.unwrap_or(2000)
}
pub fn set_series_id(&mut self, series: u64) {
@@ -129,8 +129,9 @@ impl BinnedQuery {
}
pub fn for_time_weighted_scalar(self) -> Self {
err::todo();
self
let mut v = self;
v.transform = TransformQuery::for_time_weighted_scalar();
v
}
}

View File

@@ -91,6 +91,12 @@ impl PlainEventsQuery {
}
pub fn events_max(&self) -> u64 {
self.events_max.unwrap_or(1024 * 128)
}
// A rough indication on how many bytes this request is allowed to return. Otherwise, the result should
// be a partial result.
pub fn bytes_max(&self) -> u64 {
self.events_max.unwrap_or(1024 * 512)
}