Skip to main content

ExtractionTrigger

Trait ExtractionTrigger 

Source
pub trait ExtractionTrigger:
    Send
    + Sync
    + 'static {
    // Required methods
    fn name(&self) -> &str;
    fn attach(&self, context: ExtractionTriggerContext<'_>);
}
Expand description

Decides when a store’s extraction runs (ExtractionTrigger): attach registers the hooks it needs and calls fire when extraction should happen. A trigger that never fires never extracts; MemoryManager::flush writes everything regardless.

Required Methods§

Source

fn name(&self) -> &str

A stable name for the trigger kind, used in logs.

Source

fn attach(&self, context: ExtractionTriggerContext<'_>)

Wires the trigger into the agent; called once per store when the manager initializes.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§