Skip to content

feat: Metrics API#46

Merged
tomasz-blasz merged 4 commits intomainfrom
topic/metrics
Feb 27, 2026
Merged

feat: Metrics API#46
tomasz-blasz merged 4 commits intomainfrom
topic/metrics

Conversation

@tomasz-blasz
Copy link
Contributor

No description provided.

Copilot AI review requested due to automatic review settings February 27, 2026 11:59
@tomasz-blasz tomasz-blasz force-pushed the topic/metrics branch 2 times, most recently from d412c77 to b28378a Compare February 27, 2026 12:05
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new Metrics module to the Firebolt C++ client (public API, implementation, tests, demo app integration) and aligns shared AgePolicy typing across modules/specs.

Changes:

  • Introduces Firebolt::Metrics API (IMetrics), implementation (MetricsImpl), and unit/component tests.
  • Centralizes AgePolicy into a shared firebolt/common_types.h and updates Discovery + JSON enum mapping accordingly.
  • Updates OpenRPC spec artifacts to include Metrics methods/schemas.

Reviewed changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
test/unit/metricsTest.cpp New unit tests for MetricsImpl RPC invocation paths.
test/unit/discoveryTest.cpp Updates Discovery tests to use shared Firebolt::AgePolicy.
test/component/metricsTest.cpp New component tests calling IFireboltAccessor().MetricsInterface().
test/component/discoveryTest.cpp Updates component test to use shared Firebolt::AgePolicy.
test/api_test_app/main.cpp Registers MetricsDemo in the demo app menu.
test/api_test_app/apis/metricsDemo.h Declares Metrics demo runner.
test/api_test_app/apis/metricsDemo.cpp Implements interactive demo calls for Metrics methods.
test/api_test_app/apis/discoveryDemo.cpp Switches to shared AgePolicy enum + common JSON enum mapping header.
src/metrics_impl.h Adds MetricsImpl class implementing the new interface.
src/metrics_impl.cpp Implements Metrics RPC calls and request parameter shaping.
src/json_types/jsondata_metrics_types.h Adds JSON enum mapping for Metrics::ErrorType.
src/json_types/jsondata_common.h Moves AgePolicyEnum mapping to Firebolt::JsonData for reuse across modules.
src/firebolt.cpp Wires MetricsImpl into the singleton accessor (MetricsInterface()).
src/discovery_impl.h Updates Discovery watched signature to use shared Firebolt::AgePolicy.
src/discovery_impl.cpp Updates watched request building for Firebolt::AgePolicy (but has a namespace issue).
include/firebolt/metrics.h New public Metrics API header (IMetrics, ErrorType, method docs/signatures).
include/firebolt/firebolt.h Exposes MetricsInterface() on IFireboltAccessor.
include/firebolt/discovery.h Removes Discovery::AgePolicy in favor of shared Firebolt::AgePolicy.
include/firebolt/common_types.h New shared types header (currently AgePolicy).
docs/openrpc/the-spec/firebolt-open-rpc.json Adds Metrics methods and schemas to the spec.
docs/openrpc/the-spec/firebolt-open-rpc--legacy.json Updates legacy spec output including Metrics and schema updates.
docs/openrpc/the-spec/firebolt-app-open-rpc.json Adds shared schemas (e.g., MediaPosition, ErrorType, FlatMap).
docs/openrpc/package.json Adjusts OpenRPC build scripts.
docs/openrpc/openrpc/metrics.json Adds generated per-module OpenRPC doc for Metrics.
CHANGELOG.md Notes Metrics addition and reorganizes Unreleased section details.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings February 27, 2026 12:33
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 25 out of 25 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@tomasz-blasz tomasz-blasz merged commit 193edab into main Feb 27, 2026
12 checks passed
@tomasz-blasz tomasz-blasz deleted the topic/metrics branch February 27, 2026 13:11
@github-actions github-actions bot locked and limited conversation to collaborators Feb 27, 2026
@tomasz-blasz
Copy link
Contributor Author

🎉 This PR is included in version 0.5.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants