Struct Resource Metrics Plugin
Generated from cargo doc --no-deps -p nemo-relay-builtins -p nemo-relay-diagnostics -p nemo-relay-logging -p nemo-relay-plugin-host -p nemo-relay-codecs -p nemo-relay -p nemo-relay-runtime -p nemo-relay-model-pricing -p nemo-relay-resource-metrics -p nemo-relay-observability -p nemo-relay-adaptive -p nemo-relay-pii-redaction -p nemo-relay-ffi -p nemo-relay-types -p nemo-relay-plugin -p nemo-relay-worker-proto -p nemo-relay-worker.
Built-in resource metrics component.
Implementations
impl ResourceMetricsPlugin
impl ResourceMetricsPlugin
new
pub fn new(
snapshot_sink: impl Fn() -> Result<SnapshotSink> + Send + Sync + 'static,
) -> Self
Create a component whose snapshot sink is bound by the activating runtime.
plugin_kind
pub fn plugin_kind(&self) -> &str
Component behavior independent of a concrete runtime host.
allows_multiple_components
pub fn allows_multiple_components(&self) -> bool
Component behavior independent of a concrete runtime host.
validate
pub fn validate(&self, config: &Map<String, Json>) -> Vec<ConfigDiagnostic>
Component behavior independent of a concrete runtime host.
Trait Implementations
impl Plugin for ResourceMetricsPlugin
impl Plugin for ResourceMetricsPlugin
plugin_kind
fn plugin_kind(&self) -> &str
allows_multiple_components
fn allows_multiple_components(&self) -> bool
validate
fn validate(&self, config: &Map<String, Json>) -> Vec<ConfigDiagnostic>
register
fn register<'a>(
&'a self,
config: &Map<String, Json>,
ctx: &'a mut dyn PluginRegistrationContext,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'a>>
validate_with_policy
fn validate_with_policy(
&self,
plugin_config: &Map<String, Value>,
_policy: &ConfigPolicy,
) -> Vec<ConfigDiagnostic>