iceberg-cpp
Loading...
Searching...
No Matches
Public Member Functions | List of all members
iceberg::MetricsReporter Class Referenceabstract

Interface for reporting metrics from Iceberg operations. More...

#include <metrics_reporter.h>

Inheritance diagram for iceberg::MetricsReporter:
iceberg::CollectingMetricsReporter iceberg::CompositeMetricsReporter iceberg::FailingMetricsReporter iceberg::InitializingReporter iceberg::ThrowingMetricsReporter

Public Member Functions

virtual Status Initialize (const std::unordered_map< std::string, std::string > &properties)
 Initialize the reporter with catalog properties after construction.
 
virtual Status Report (const MetricsReport &report)=0
 Report a metrics report.
 

Detailed Description

Interface for reporting metrics from Iceberg operations.

Implementations of this interface can be used to collect and report metrics about scan and commit operations. Common implementations include logging reporters, metrics collectors, and the noop reporter for testing.

Implementations must not throw. Return an error Status instead.

Member Function Documentation

◆ Initialize()

virtual Status iceberg::MetricsReporter::Initialize ( const std::unordered_map< std::string, std::string > &  properties)
inlinevirtual

Initialize the reporter with catalog properties after construction.

Called by MetricsReporters::Load() before the first Report() invocation. The default implementation is a no-op. Override to perform property-based setup (e.g., configure endpoints, credentials, sampling rates).

Reimplemented in iceberg::InitializingReporter.

◆ Report()

virtual Status iceberg::MetricsReporter::Report ( const MetricsReport &  report)
pure virtual

Report a metrics report.

Implementations should handle the report according to their purpose (e.g., logging, sending to a metrics service, etc.).

Parameters
reportThe metrics report to process.

Implemented in iceberg::FailingMetricsReporter, iceberg::ThrowingMetricsReporter, iceberg::InitializingReporter, iceberg::CompositeMetricsReporter, and iceberg::CollectingMetricsReporter.


The documentation for this class was generated from the following file: