pub struct HostingConfig {
pub list_default_limit: usize,
pub list_max_limit: usize,
pub batch_max_databases: usize,
pub batch_default_k: usize,
pub batch_max_k: usize,
pub action_default_k: usize,
pub action_max_k: usize,
pub request_timeout: Option<Duration>,
pub enrich_workers: usize,
pub ready_probe_db: Option<String>,
}Expand description
Settings for the hosting endpoints and middleware.
Fields§
§list_default_limit: usizePage size of GET /memories when limit is not given.
list_max_limit: usizeLargest page GET /memories returns (MENTEDB_LIST_MAX_LIMIT).
batch_max_databases: usizeMost databases one batch search may name (MENTEDB_BATCH_MAX_DATABASES).
batch_default_k: usizeResults per database when a batch search gives no k.
batch_max_k: usizeMost results per database one batch search may ask for.
action_default_k: usizeResults of recall_for_action when no k is given.
action_max_k: usizeMost results one recall_for_action may ask for.
request_timeout: Option<Duration>Upper bound on every request (MENTEDB_REQUEST_TIMEOUT_MS); a
request’s own deadline header can only shorten it. None: no bound.
enrich_workers: usizeThreads in the enrichment pool, which is also the most enrichment runs
at once (MENTEDB_ENRICH_WORKERS).
ready_probe_db: Option<String>Named database /v1/ready opens (and so locks) to prove databases can
be opened (MENTEDB_READY_PROBE_DB; empty turns the check off).
Implementations§
Source§impl HostingConfig
impl HostingConfig
Trait Implementations§
Source§impl Clone for HostingConfig
impl Clone for HostingConfig
Source§impl Debug for HostingConfig
impl Debug for HostingConfig
Auto Trait Implementations§
impl Freeze for HostingConfig
impl RefUnwindSafe for HostingConfig
impl Send for HostingConfig
impl Sync for HostingConfig
impl Unpin for HostingConfig
impl UnsafeUnpin for HostingConfig
impl UnwindSafe for HostingConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request