pub struct CalibrationStore<B>where
B: StorageBackend,{ /* private fields */ }Expand description
Calibration parameter store over any StorageBackend: the writer API for
the P2.2 re-fit loop and the reader API for serving.
Implementations§
Source§impl<B> CalibrationStore<B>where
B: StorageBackend,
impl<B> CalibrationStore<B>where
B: StorageBackend,
pub fn new(backend: Arc<B>) -> CalibrationStore<B>
Sourcepub async fn insert(&self, params: &CalibrationParams) -> Result<(), Status>
pub async fn insert(&self, params: &CalibrationParams) -> Result<(), Status>
Insert one validated parameter row. The (primitive, version triple) key
must be new — re-fits mint a fresh calib_version; rows are never
updated in place.
Sourcepub async fn latest(
&self,
schema_id: &str,
model_id: &str,
primitive: DecisionPrimitive,
) -> Result<Option<CalibrationParams>, Status>
pub async fn latest( &self, schema_id: &str, model_id: &str, primitive: DecisionPrimitive, ) -> Result<Option<CalibrationParams>, Status>
The newest parameter row for a (schema, model, primitive), by fit time.
Sourcepub async fn history(
&self,
schema_id: &str,
model_id: &str,
primitive: DecisionPrimitive,
) -> Result<Vec<CalibrationParams>, Status>
pub async fn history( &self, schema_id: &str, model_id: &str, primitive: DecisionPrimitive, ) -> Result<Vec<CalibrationParams>, Status>
All parameter versions for a (schema, model, primitive), newest first.
Auto Trait Implementations§
impl<B> Freeze for CalibrationStore<B>
impl<B> RefUnwindSafe for CalibrationStore<B>where
B: RefUnwindSafe,
impl<B> Send for CalibrationStore<B>
impl<B> Sync for CalibrationStore<B>
impl<B> Unpin for CalibrationStore<B>
impl<B> UnsafeUnpin for CalibrationStore<B>
impl<B> UnwindSafe for CalibrationStore<B>where
B: RefUnwindSafe,
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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
Mutably borrows from an owned value. Read more
§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
Converts
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>
Converts
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 more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ServiceExt for T
impl<T> ServiceExt for T
§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more