- example_iot_load_test: simulates N devices (default 100 across 10 groups: 55 + 9×5) pushing DeploymentState every tick to NATS, no real podman. Applies one Deployment CR per group, runs for a bounded duration, verifies each CR's .status.aggregate counters sum to the target device count. - iot/scripts/load-test.sh: minimum harness — k3d cluster + NATS via NatsBasicScore + CRD + operator + load-test binary. No VM, no agent build. - operator: connect_with_retry() on startup. The NATS TCP probe that the smoke scripts do isn't enough to guarantee the protocol handshake is ready (k3d loadbalancer can accept SYNs before the pod is serving); the load harness hit this racing against a freshly-rebuilt operator binary. - drop unused rand dep from iot-agent-v0 Cargo.toml. 100-device run: 6002 state writes in 60s at a clean 100 writes/s, all 10 CR aggregates converge to target_devices.len() (e.g. group-00 → 55 = 45 Running + 9 Failed + 1 Pending).
20 lines
620 B
TOML
20 lines
620 B
TOML
[package]
|
|
name = "iot-agent-v0"
|
|
version = "0.1.0"
|
|
edition = "2024"
|
|
rust-version = "1.85"
|
|
|
|
[dependencies]
|
|
harmony-reconciler-contracts = { path = "../../harmony-reconciler-contracts" }
|
|
harmony = { path = "../../harmony", default-features = false, features = ["podman"] }
|
|
async-nats = { workspace = true }
|
|
chrono = { workspace = true }
|
|
futures-util = { workspace = true }
|
|
serde = { workspace = true }
|
|
serde_json = { workspace = true }
|
|
tokio = { workspace = true }
|
|
tracing = { workspace = true }
|
|
tracing-subscriber = { workspace = true }
|
|
anyhow = { workspace = true }
|
|
clap = { workspace = true }
|
|
toml = { workspace = true } |