All checks were successful
Run Check Script / check (pull_request) Successful in 2m29s
Review feedback: "iot" is the wrong scope label. The pattern this crate encodes — a central operator writing desired state to NATS JetStream KV, a remote agent watching KV and reconciling — is the foundation for harmony's decentralized infrastructure management, not an IoT thing. Raspberry Pi is one concrete use case; the next consumers (OKD fleet agents, edge-compute reconcilers, any host harmony can't reach directly over a control-plane API) aren't IoT either. Rename the crate to reflect what it actually is: - `iot/iot-contracts/` → `harmony-reconciler-contracts/` (moved to the repo root, alongside the other support crates). - Package name `iot-contracts` → `harmony-reconciler-contracts`. - Consumer `Cargo.toml` path references updated in operator, agent. - `use iot_contracts::…` → `use harmony_reconciler_contracts::…` across agent + operator sources. - Crate-level prose in lib.rs + kv.rs rewritten to drop the IoT framing and describe the reconciler pattern in its own terms. - harmony/Cargo.toml drops the dep entirely — after the preceding commit moved podman Score types back in-tree, harmony no longer pulls anything from this crate. No behavior change. Wire format unchanged — the two existing public modules (`kv`, `status`) are byte-identical. Verified: - `cargo check --all-targets --all-features` clean. - `cargo test -p harmony-reconciler-contracts` — 5/5 pass. - x86_64 `smoke-a3.sh` end-to-end PASS (reboot-reconnect included). Out of scope / follow-up: the operator and agent crate names (`iot-operator-v0`, `iot-agent-v0`) and `IotScore` are still IoT-branded. Evaluating whether to flip those in this branch next.
21 lines
836 B
TOML
21 lines
836 B
TOML
[package]
|
|
name = "harmony-reconciler-contracts"
|
|
version = "0.1.0"
|
|
edition = "2024"
|
|
license.workspace = true
|
|
|
|
# Cross-boundary types shared between a harmony operator (central,
|
|
# writing desired state to NATS JetStream KV) and a harmony agent
|
|
# (on-host, watching KV and reconciling). Deliberately lean: pure
|
|
# serde data types, bucket/key constants, small helpers. No tokio,
|
|
# no async-nats, no harmony. The on-device agent build pulls this
|
|
# in alongside a minimal async-nats client; the operator pulls it
|
|
# alongside kube-rs; harmony itself treats it as just another
|
|
# module. None of those consumers should pay for the others' deps.
|
|
|
|
[dependencies]
|
|
chrono = { workspace = true, features = ["serde"] }
|
|
harmony_types = { path = "../harmony_types" }
|
|
serde = { workspace = true, features = ["derive"] }
|
|
serde_json = { workspace = true }
|