wasmcloud_core/
lib.rs

1#![forbid(clippy::unwrap_used)]
2
3pub mod logging;
4pub mod nats;
5pub mod tls;
6
7pub mod host;
8pub use host::*;
9
10pub mod link;
11pub use link::*;
12
13pub mod otel;
14pub use otel::*;
15
16#[cfg(feature = "oci")]
17pub mod oci;
18#[cfg(feature = "oci")]
19pub use oci::*;
20
21pub mod par;
22pub use par::*;
23
24pub mod registry;
25pub use registry::*;
26
27pub mod rpc;
28pub use rpc::*;
29
30pub mod secrets;
31
32pub mod wit;
33pub use wit::*;
34
35/// The 1.0 version of the wasmCloud control API, used in topic strings for the control API
36pub const CTL_API_VERSION_1: &str = "v1";
37
38/// Identifier of one or more entities on the lattice used for addressing. May take many forms, such as:
39/// - component public key
40/// - provider public key
41/// - opaque string
42pub type LatticeTarget = String;
43
44/// Identifier of a component which sends invocations on the lattice
45pub type ComponentId = String;
46
47/// Name of a link on the wasmCloud lattice
48pub type LinkName = String;
49
50/// Public key (nkey) of a cluster issuer
51pub type ClusterIssuerKey = String;
52
53/// WIT package for a given operation (ex. `keyvalue` in `wasi:keyvalue/readwrite.get`)
54pub type WitPackage = String;
55
56/// WIT namespace for a given operation (ex. `wasi` in `wasi:keyvalue/readwrite.get`)
57pub type WitNamespace = String;
58
59/// WIT interface for a given operation (ex. `readwrite` in `wasi:keyvalue/readwrite.get`)
60pub type WitInterface = String;
61
62/// A WIT function (ex. `get` in `wasi:keyvalue/readwrite.get`)
63pub type WitFunction = String;
64
65/// The name of a known (possibly pre-created) configuration, normally used when creating
66/// new interface links in order to configure one or both source/target
67pub type KnownConfigName = String;
68
69/// Trait describing types/entities that can be health-checked
70pub trait HealthCheck {
71    // This might not work with codegen and we'll have to impl
72    fn health_request(&self) -> HealthCheckResponse;
73}