Skip to main content

canic_control_plane/
lib.rs

1//! Control-plane runtime for root and `wasm_store` orchestration.
2//!
3//! This crate layers the template publication and managed-store workflows on
4//! top of `canic-core` and is re-exported through the `canic` facade when the
5//! control-plane feature is enabled.
6
7canic_core::ic_memory_range!(
8    authority = CANIC_CONTROL_PLANE_MEMORY_AUTHORITY,
9    start = canic_core::role_contract::allocation::CANIC_CONTROL_PLANE_MIN_ID,
10    end = canic_core::role_contract::allocation::CANIC_CONTROL_PLANE_MAX_ID,
11);
12
13#[cfg(test)]
14const _: () = {
15    fn __canic_memory_test_bootstrap() {
16        canic_core::api::runtime::MemoryRuntimeApi::bootstrap_registry()
17            .expect("test stable-memory bootstrap");
18    }
19
20    #[canic_core::__reexports::ctor::ctor(
21        unsafe,
22        anonymous,
23        crate_path = canic_core::__reexports::ctor
24    )]
25    fn __canic_install_memory_test_bootstrap_hook() {
26        canic_core::memory::runtime::install_test_bootstrap_hook(__canic_memory_test_bootstrap);
27    }
28};
29
30pub mod api;
31pub(crate) mod config;
32pub mod dto;
33pub mod ids;
34pub(crate) mod ops;
35#[cfg(feature = "root-control-plane")]
36pub(crate) mod runtime;
37pub(crate) mod schema;
38pub mod state_contract;
39pub(crate) mod storage;
40#[cfg(feature = "root-control-plane")]
41pub(crate) mod view;
42#[cfg(feature = "root-control-plane")]
43pub(crate) mod workflow;