generated from rmcguire/go-server-with-otel
132 lines
5.8 KiB
Markdown
132 lines
5.8 KiB
Markdown
# Changelog
|
|
|
|
All notable changes to econet-exporter are documented here. The format is
|
|
based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this
|
|
project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
|
|
## [Unreleased]
|
|
|
|
## [v0.5.0] - 2026-07-16
|
|
|
|
### Added
|
|
|
|
* **Admin UI** at `/` (`econetui`): a server-rendered dashboard of devices and
|
|
their status (connectivity, running state, setpoint, hot-water, alerts) with a
|
|
per-device mode dropdown that writes via the in-process gRPC server. HTMX for
|
|
interactivity (30s auto-refresh, card-level swaps), Pico.css + embedded SVG
|
|
icons per device type, a hot-water **fill-level meter**, a 🐛 debug button
|
|
that shows the raw device JSON, and a persisted **dark-mode toggle** — all
|
|
served from a single binary via `embed.FS`, responsive down to mobile. Mode
|
|
changes show a best-effort, TTL-bounded "Updating…" pending badge that
|
|
reconciles against the reported state (or falls back to a fresh fetch if it
|
|
never lands). Auth is intentionally left to the edge (e.g. oauth2-proxy);
|
|
`/health` and `/metrics` stay unauthenticated.
|
|
* `enableWebUI` config (env `ECONET_ENABLE_WEB_UI`, default **true**) to toggle
|
|
the admin UI, and `disableWaterUsage` (env `ECONET_DISABLE_WATER_USAGE`,
|
|
default false) to skip the per-device water-usage REST call on units that
|
|
don't report it.
|
|
* `MODE_ELECTRIC_GAS` added to the `Mode` enum — real devices report a combined
|
|
"Electric/Gas" mode that was previously decoded as unknown and dropped from
|
|
the settable-mode list.
|
|
* `supported_modes` on the `Device` proto message (the settable modes for that
|
|
unit), populated from the device's reported mode list and surfaced over gRPC,
|
|
REST, and MCP.
|
|
|
|
## [v0.4.0] - 2026-07-16
|
|
|
|
### Added
|
|
|
|
* **Mode control (first mutating RPC).** New `SetMode` RPC on `EconetService`,
|
|
exposed over gRPC, the REST gateway (`POST /v1alpha1/devices/{serial}/mode`),
|
|
and as an MCP tool. Writes go out over ClearBlade's REST publish endpoint
|
|
(`POST /message/{systemKey}/publish`, topic `user/{account_id}/device/desired`,
|
|
payload `{"@MODE": <idx>, ...}`) — the HTTP equivalent of the app's MQTT
|
|
publish, so **no MQTT client is required**. The mode is applied
|
|
asynchronously by the Rheem cloud and only reflected on a later poll.
|
|
* `Mode` proto enum (`off`, `electric`, `energy-saving`, `heat-pump`,
|
|
`high-demand`, `gas`, `performance`, `vacation`) with protovalidate rejecting
|
|
the unspecified value. The enum flows into the MCP tool's input schema, so
|
|
clients see the valid modes. Supported modes are validated per-device against
|
|
the unit's reported mode list (`@MODE` is published as an index into it).
|
|
* Generated MCP server (`econetmcpgen`) built from the proto via
|
|
`protoc-gen-go-mcp`, now mounted at `/api/mcp`, forwarding in-process to the
|
|
gRPC server through the go-sdk adapter. The hand-written `econetmcp` package
|
|
is retained as a one-line-switchable fallback in `pkg/econet/econet.go`.
|
|
* Optional Grafana dashboard shipped as a ConfigMap in the Helm chart. Enable
|
|
with `hull.config.settings.grafanaDashboard.enabled=true`; the ConfigMap is
|
|
labeled `grafana_dashboard: "1"` for the Grafana sidecar to auto-import. The
|
|
dashboard uses the default Prometheus datasource (no hard-coded UID) and has a
|
|
multi-select `Device` filter driven by `econet_friendly_name`. Covers connect/
|
|
heating/mode/setpoint/hot-water/alerts, setpoint range, hot-water availability,
|
|
energy + cost + water usage, a heating-state timeline, WiFi signal, and a
|
|
device-info table. Sidecar label/value and Grafana folder are configurable.
|
|
|
|
### Changed
|
|
|
|
* MCP tool surface changed with the switch to generated tools: `/api/mcp` now
|
|
serves `econet_v1alpha1_EconetService_ListDevices`, `_GetDevice`, and
|
|
`_SetMode` (structured JSON output) instead of the single `list_water_heaters`
|
|
summary tool. Switch back via the aliased import in `pkg/econet/econet.go`.
|
|
|
|
## [v0.3.0] - 2026-07-05
|
|
|
|
### Changed
|
|
|
|
* Replaced the third-party `kevinburke/rheemcloud-go` dependency and its MQTT
|
|
coupling with an in-repo `econetclient` REST poller that talks directly to
|
|
the Rheem/EcoNet cloud REST API. Device state (including `@RUNNING`, `@MODE`,
|
|
and `@STATUS`) is sourced from the REST `getUserDataForApp` payload, so no
|
|
MQTT connection is required.
|
|
|
|
### Removed
|
|
|
|
* `rheemcloud` package and its `go.mod`/`go.sum` entries.
|
|
|
|
## [v0.2.0] - 2026-07-05
|
|
|
|
### Added
|
|
|
|
* `econetTLSInsecure` config option (env `ECONET_TLS_INSECURE`) to skip TLS
|
|
certificate verification when
|
|
connecting to the Rheem/EcoNet cloud API. The upstream host (cloudblade)
|
|
serves an old/untrusted certificate chain; this is a stopgap and should be
|
|
removed once the upstream certificate is fixed. See AGENTS.md.
|
|
* `TODO.md` tracking outstanding work (CA cert bundle, mutating proto RPCs,
|
|
additional tracing spans).
|
|
|
|
## [v0.1.2] - 2026-07-04
|
|
|
|
### Added
|
|
|
|
* CA certificate bundle baked into the container image so the exporter can
|
|
establish TLS connections to the EcoNet API.
|
|
|
|
### Changed
|
|
|
|
* Bumped Helm chart versions.
|
|
|
|
## [v0.1.1] - 2026-07-04
|
|
|
|
### Fixed
|
|
|
|
* Corrected the Helm chart `appVersion`.
|
|
|
|
## [v0.1.0] - 2026-07-04
|
|
|
|
Initial release of the EcoNet exporter for Rheem / Rheemcloud water heaters,
|
|
built on the `go-app` framework.
|
|
|
|
### Added
|
|
|
|
* `EconetService` owning a single shared `*rheemcloud.Client` across the gRPC,
|
|
MCP, and metrics sub-servers (fail-fast on missing credentials).
|
|
* gRPC API (`ListDevices`, `GetDevice`) with proto definitions and
|
|
grpc-gateway REST bindings.
|
|
* MCP server at `/api/mcp` exposing a `list_water_heaters` tool.
|
|
* OpenTelemetry observable gauges for device state (temperature, mode, energy
|
|
and water usage, cost) with a background usage poller, exported to
|
|
Prometheus. Units are encoded in metric names (`_fahrenheit`, `_kwh`,
|
|
`_gallons`, `_dollars`).
|
|
* `costPerKWH` config (US dollars per kWh) feeding `econet_energy_cost_dollars`.
|
|
* Helm chart for Kubernetes deployment.
|