pub struct CatalogEntry {
pub module_id: String,
pub module_version: Option<String>,
pub roles: Vec<ProviderRole>,
pub control_ops: Vec<String>,
}Fields§
§module_id: String§module_version: Option<String>The registered module’s self-declared build version, projected from its manifest so a consumer can tell WHICH BUILD of a module it is talking to at connect time.
Without this, a client compiled against a module’s current source reads a contract that is true of the repository and false of the running process – the types match, the JSON decodes, and the meaning has changed. That failure carries no error to notice; the version in the catalog turns a semantic skew into a log line at connect instead of a wrong sentence on a user’s screen.
Optional on the wire only because entries serialized by older daemons lack it: absent means “daemon predates the field”, never “module has no version” (the manifest field is required at registration).
The reading is ARMED BY OBSERVATION, not by this documentation: until a consumer has seen at least one populated entry from the daemon it is connected to, an all-None catalog is indistinguishable from an old daemon, and a client shipping the documented reading against it would hold a guarantee it does not have.
roles: Vec<ProviderRole>§control_ops: Vec<String>Trait Implementations§
Source§impl Clone for CatalogEntry
impl Clone for CatalogEntry
Source§fn clone(&self) -> CatalogEntry
fn clone(&self) -> CatalogEntry
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more