pub mod local;
pub mod remote;
use somatize_compiler::ExecutionPlan;
use somatize_core::cache::CacheStore;
use somatize_core::error::Result;
use somatize_core::value::Value;
use std::collections::HashMap;
use crate::EventBus;
use crate::filter_library::FilterLibrary;
use std::sync::Arc;
pub trait Runner: Send + Sync {
fn fit(
&self,
plan: &ExecutionPlan,
filters: &FilterLibrary,
cache: &dyn CacheStore,
event_bus: &Arc<EventBus>,
input: &Value,
y: Option<&Value>,
) -> Result<(Value, HashMap<String, Value>)>;
fn forward(
&self,
plan: &ExecutionPlan,
filters: &FilterLibrary,
cache: &dyn CacheStore,
event_bus: &Arc<EventBus>,
input: &Value,
) -> Result<Value>;
}
pub use local::LocalRunner;
pub use remote::{RemoteRunner, Transport};