pub struct ProfileStore { /* private fields */ }Expand description
Profile store for managing agent profiles.
Implementations§
Source§impl ProfileStore
impl ProfileStore
Sourcepub fn store(&self, profile: AgentProfile)
pub fn store(&self, profile: AgentProfile)
Store/overwrite a profile keyed by agent_id.
Sourcepub fn get(&self, agent_id: &str) -> Option<AgentProfile>
pub fn get(&self, agent_id: &str) -> Option<AgentProfile>
Retrieve a profile by agent_id.
Sourcepub fn validate_token(&self, token: &str) -> Option<AgentProfile>
pub fn validate_token(&self, token: &str) -> Option<AgentProfile>
Validate a bearer token and return the associated profile (if present and valid).
Sourcepub fn list(&self) -> Vec<AgentProfile>
pub fn list(&self) -> Vec<AgentProfile>
List all stored profiles.
Sourcepub fn remove(&self, agent_id: &str) -> Option<AgentProfile>
pub fn remove(&self, agent_id: &str) -> Option<AgentProfile>
Remove a profile by agent_id.
Trait Implementations§
Source§impl Debug for ProfileStore
impl Debug for ProfileStore
Source§impl Default for ProfileStore
impl Default for ProfileStore
Source§fn default() -> ProfileStore
fn default() -> ProfileStore
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for ProfileStore
impl RefUnwindSafe for ProfileStore
impl Send for ProfileStore
impl Sync for ProfileStore
impl Unpin for ProfileStore
impl UnwindSafe for ProfileStore
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
Mutably borrows from an owned value. Read more
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§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>
§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].