# Changelog

All notable changes to the `sunbeam-g2v` crate are documented in this file.

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]

## [0.3.0] - 2026-06-22

### Added

- New `ConfigError` enum in `sunbeam_g2v::config`, backed by `thiserror`, for typed configuration failures.
- `From<ConfigError>` implementation for `ServiceError` so config errors convert cleanly into the framework error type.
- `ConfigError` re-exported from `sunbeam_g2v::prelude`.

### Changed

- **Breaking:** `ServiceConfig::load()` now returns `Result<Self, ConfigError>` instead of `Result<Self, figment::Error>`.
- Feature flags now correctly gate modules, optional dependencies, integration tests, and the `simple` example. The crate compiles with `default-features = false` and with arbitrary selective feature combinations.
- Moved `JwtClaims` to the core `auth` module so it is available without enabling JWT middleware.
- Updated `tracing-opentelemetry` to 0.33 and refreshed the lockfile to latest compatible versions.
- Suppressed the `result_large_err` warning by boxing the inner `figment::Error` inside `ConfigError`.

### Fixed

- Fixed `[lints.clippy]` configuration for `refining_impl_trait_internal` and `refining_impl_trait_reachable`; these are Rust compiler lints, not Clippy lints.
- Resolved assorted Clippy warnings across authentication, client, testing, metrics, and election modules.

## [0.2.1] - 2026-06-22

### Added

- `KetoClient::list_relation_tuples` and `KetoClient::delete_relation_tuples` methods.
- `ReadService` proto for relation-tuple reads.
- Integration tests for the new Keto relation-tuple operations.
- Re-exported `RelationTuple` and `Subject` from `middleware::auth`.

### Fixed

- Prometheus 0.14 label-value type inference compile failures in metrics calls.

## [0.2.0] - 2026-06-22

### Added

- Initial published release of the ConnectRPC-based Sunbeam service framework.
- Axum and standalone server builders, service router, and lifecycle hooks.
- JWT and Ory Keto authentication middleware.
- Prometheus metrics, OpenTelemetry tracing, and request-id middleware.
- SQLx/Postgres database integration, NATS / JetStream messaging, and leader election (Vault/OpenBAO and NATS).
- Client utilities including retry and circuit-breaker Tower layers.
- `TestHarness` and testcontainer placeholder utilities.

### Changed

- Updated README with current feature flags and a working quick-start example.
- Included README in crate-level rustdoc for docs.rs.

### Fixed

- Compilation errors after dependency upgrades.
- Broken intra-doc links.
- Added missing documentation to generated Keto proto types.

[Unreleased]: https://github.com/sunbeamdotpt/g2v/compare/v0.3.0...HEAD
[0.3.0]: https://github.com/sunbeamdotpt/g2v/compare/v0.2.1...v0.3.0
[0.2.1]: https://github.com/sunbeamdotpt/g2v/compare/v0.2.0...v0.2.1
[0.2.0]: https://github.com/sunbeamdotpt/g2v/releases/tag/v0.2.0
