themql-core 0.1.0

Native Rust message-query runtime for desktop, distributed, telemetry, analysis, AI, GNC, and embedded systems.
Documentation

themql-core

Canonical owner of theMQL's core type identities: Message, Query, Response, Error, Context, and Resource identity.

Every other crate in theMQL is subordinate to this one for type definitions. See specs/core.toml for the authoritative specification.

Authority

Per SPEC.toml and prompts/SYSTEM.md, the canonical types here are the semantic owners. Transport adapters (themql-mqtt, themql-graphql, themql-sse) project these types; they do not redefine them.

Example

use themql_core::{Message, MessageId, Subject, Operation, Payload,
                   Metadata, Timestamp, TimestampKind};

let subject = Subject::from_str("vehicle.sensors.imu.gyro")
    .expect("valid subject");
let msg = Message {
    id: MessageId::new(),
    timestamp: Timestamp::now_monotonic(),
    subject,
    operation: Operation::Telemetry,
    payload: Payload::Unit,
    metadata: Metadata::default(),
};
assert_eq!(msg.operation, Operation::Telemetry);