pub trait Deploy<'a> {
type Meta: Default;
type InstantiateEnv;
type Process: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + Clone;
type Cluster: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + Clone;
type External: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + RegisterPort<'a, Self>;
Show 17 methods
// Required methods
fn o2o_sink_source(
p1: &Self::Process,
p1_port: &<Self::Process as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
) -> (Expr, Expr);
fn o2o_connect(
p1: &Self::Process,
p1_port: &<Self::Process as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
) -> Box<dyn FnOnce()>;
fn o2m_sink_source(
p1: &Self::Process,
p1_port: &<Self::Process as Node>::Port,
c2: &Self::Cluster,
c2_port: &<Self::Cluster as Node>::Port,
) -> (Expr, Expr);
fn o2m_connect(
p1: &Self::Process,
p1_port: &<Self::Process as Node>::Port,
c2: &Self::Cluster,
c2_port: &<Self::Cluster as Node>::Port,
) -> Box<dyn FnOnce()>;
fn m2o_sink_source(
c1: &Self::Cluster,
c1_port: &<Self::Cluster as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
) -> (Expr, Expr);
fn m2o_connect(
c1: &Self::Cluster,
c1_port: &<Self::Cluster as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
) -> Box<dyn FnOnce()>;
fn m2m_sink_source(
c1: &Self::Cluster,
c1_port: &<Self::Cluster as Node>::Port,
c2: &Self::Cluster,
c2_port: &<Self::Cluster as Node>::Port,
) -> (Expr, Expr);
fn m2m_connect(
c1: &Self::Cluster,
c1_port: &<Self::Cluster as Node>::Port,
c2: &Self::Cluster,
c2_port: &<Self::Cluster as Node>::Port,
) -> Box<dyn FnOnce()>;
fn e2o_many_source(
extra_stmts: &mut Vec<Stmt>,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
codec_type: &Type,
shared_handle: String,
) -> Expr;
fn e2o_many_sink(shared_handle: String) -> Expr;
fn e2o_source(
extra_stmts: &mut Vec<Stmt>,
p1: &Self::External,
p1_port: &<Self::External as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
codec_type: &Type,
shared_handle: String,
) -> Expr;
fn e2o_connect(
p1: &Self::External,
p1_port: &<Self::External as Node>::Port,
p2: &Self::Process,
p2_port: &<Self::Process as Node>::Port,
many: bool,
server_hint: NetworkHint,
) -> Box<dyn FnOnce()>;
fn o2e_sink(
p1: &Self::Process,
p1_port: &<Self::Process as Node>::Port,
p2: &Self::External,
p2_port: &<Self::External as Node>::Port,
shared_handle: String,
) -> Expr;
fn cluster_ids(
of_cluster: LocationKey,
) -> impl QuotedWithContext<'a, &'a [TaglessMemberId], ()> + Clone + 'a;
fn cluster_self_id( ) -> impl QuotedWithContext<'a, TaglessMemberId, ()> + Clone + 'a;
fn cluster_membership_stream(
location_id: &LocationId,
) -> impl QuotedWithContext<'a, Box<dyn Stream<Item = (TaglessMemberId, MembershipEvent)> + Unpin>, ()>;
// Provided method
fn register_embedded_input(
_env: &mut Self::InstantiateEnv,
_ident: &Ident,
_element_type: &Type,
) { ... }
}Available on crate feature
build only.Required Associated Types§
type Meta: Default
type InstantiateEnv
type Process: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + Clone
type Cluster: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + Clone
type External: Node<Meta = Self::Meta, InstantiateEnv = Self::InstantiateEnv> + RegisterPort<'a, Self>
Required Methods§
fn o2o_sink_source( p1: &Self::Process, p1_port: &<Self::Process as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, ) -> (Expr, Expr)
fn o2o_connect( p1: &Self::Process, p1_port: &<Self::Process as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, ) -> Box<dyn FnOnce()>
fn o2m_sink_source( p1: &Self::Process, p1_port: &<Self::Process as Node>::Port, c2: &Self::Cluster, c2_port: &<Self::Cluster as Node>::Port, ) -> (Expr, Expr)
fn o2m_connect( p1: &Self::Process, p1_port: &<Self::Process as Node>::Port, c2: &Self::Cluster, c2_port: &<Self::Cluster as Node>::Port, ) -> Box<dyn FnOnce()>
fn m2o_sink_source( c1: &Self::Cluster, c1_port: &<Self::Cluster as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, ) -> (Expr, Expr)
fn m2o_connect( c1: &Self::Cluster, c1_port: &<Self::Cluster as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, ) -> Box<dyn FnOnce()>
fn m2m_sink_source( c1: &Self::Cluster, c1_port: &<Self::Cluster as Node>::Port, c2: &Self::Cluster, c2_port: &<Self::Cluster as Node>::Port, ) -> (Expr, Expr)
fn m2m_connect( c1: &Self::Cluster, c1_port: &<Self::Cluster as Node>::Port, c2: &Self::Cluster, c2_port: &<Self::Cluster as Node>::Port, ) -> Box<dyn FnOnce()>
fn e2o_many_source( extra_stmts: &mut Vec<Stmt>, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, codec_type: &Type, shared_handle: String, ) -> Expr
fn e2o_many_sink(shared_handle: String) -> Expr
fn e2o_source( extra_stmts: &mut Vec<Stmt>, p1: &Self::External, p1_port: &<Self::External as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, codec_type: &Type, shared_handle: String, ) -> Expr
fn e2o_connect( p1: &Self::External, p1_port: &<Self::External as Node>::Port, p2: &Self::Process, p2_port: &<Self::Process as Node>::Port, many: bool, server_hint: NetworkHint, ) -> Box<dyn FnOnce()>
fn o2e_sink( p1: &Self::Process, p1_port: &<Self::Process as Node>::Port, p2: &Self::External, p2_port: &<Self::External as Node>::Port, shared_handle: String, ) -> Expr
fn cluster_ids( of_cluster: LocationKey, ) -> impl QuotedWithContext<'a, &'a [TaglessMemberId], ()> + Clone + 'a
fn cluster_self_id() -> impl QuotedWithContext<'a, TaglessMemberId, ()> + Clone + 'a
fn cluster_membership_stream( location_id: &LocationId, ) -> impl QuotedWithContext<'a, Box<dyn Stream<Item = (TaglessMemberId, MembershipEvent)> + Unpin>, ()>
Provided Methods§
Sourcefn register_embedded_input(
_env: &mut Self::InstantiateEnv,
_ident: &Ident,
_element_type: &Type,
)
fn register_embedded_input( _env: &mut Self::InstantiateEnv, _ident: &Ident, _element_type: &Type, )
Registers an embedded input for the given ident and element type.
Only meaningful for the embedded deployment backend. The default implementation panics.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementors§
Source§impl<'a> Deploy<'a> for HydroDeploy
Available on crate feature deploy only.
impl<'a> Deploy<'a> for HydroDeploy
Available on crate feature
deploy only.type Meta = SparseSecondaryMap<LocationKey, Vec<TaglessMemberId>>
type InstantiateEnv = Deployment
type Process = DeployNode
type Cluster = DeployCluster
type External = DeployExternal
Source§impl<'a> Deploy<'a> for MaelstromDeploy
Available on crate features maelstrom and deploy only.
impl<'a> Deploy<'a> for MaelstromDeploy
Available on crate features
maelstrom and deploy only.type Meta = ()
type InstantiateEnv = MaelstromDeployment
type Process = MaelstromProcess
type Cluster = MaelstromCluster
type External = MaelstromExternal
Source§impl<'a> Deploy<'a> for EmbeddedDeploy
impl<'a> Deploy<'a> for EmbeddedDeploy
type Meta = ()
type InstantiateEnv = EmbeddedInstantiateEnv
type Process = EmbeddedNode
type Cluster = EmbeddedNode
type External = EmbeddedNode
Source§impl<'a> Deploy<'a> for DockerDeploy
Available on crate features docker_deploy and deploy only.
impl<'a> Deploy<'a> for DockerDeploy
Available on crate features
docker_deploy and deploy only.