This reference describes unreleased code on main; no release documents it yet.

rlmesh::env::EnvFactoryExt

traitPreviewuse rlmesh::env::EnvFactoryExt;[source]

Construction, stamping and serving operations for every EnvFactory.

trait EnvFactoryExt: EnvFactory + sealed::Sealed

Also available as rlmesh::EnvFactoryExt.

make_env

provided method[source]
fn make_env(&mut self, kwargs: &Kwargs) -> Result<MadeEnv>

make with the kwargs bound (each discriminant’s default applied; a value outside its choices is the ValueError class before make runs), then stamped: the branch’s tags, the branch under ENV_BRANCH_METADATA_KEY, and reset_options under ENV_RESET_OPTIONS_KEY.

describe

provided method[source]
fn describe() -> Result<Metadata> where Self: Default

This factory type’s describe envelope. Best-effort: each build default-constructs a factory, and a failed build or space read is an env_spec badge.

serve

provided method[source]
fn serve(
    &mut self,
    address: &str,
    options: EnvFactoryServeOptions,
) -> Result<()>

Host this factory’s env on address, blocking. Runs the branch check and prepare(), makes one env (or num_envs lanes), resolves the edition, publishes the describe envelope on the handshake, and serves in the foreground. The factory is not closed.

serve_async

provided method[source]
fn serve_async(
    &mut self,
    address: &str,
    options: EnvFactoryServeOptions,
) -> impl std::future::Future<Output = Result<()>>

The async twin of serve: the pre-serve hooks run on the polling thread inside the first poll, then every lane serves from library threads; dropping the future stops the server and closes the envs it made.