27#include <unordered_map>
48 case MetricsReportType::kScanReport:
50 case MetricsReportType::kCommitReport:
69 using T = std::decay_t<
decltype(r)>;
70 if constexpr (std::is_same_v<T, ScanReport>) {
71 return MetricsReportType::kScanReport;
73 return MetricsReportType::kCommitReport;
96 [[maybe_unused]]
const std::unordered_map<std::string, std::string>& properties) {
Interface for reporting metrics from Iceberg operations.
Definition metrics_reporter.h:86
virtual Status Initialize(const std::unordered_map< std::string, std::string > &properties)
Initialize the reporter with catalog properties after construction.
Definition metrics_reporter.h:95
virtual Status Report(const MetricsReport &report)=0
Report a metrics report.
Definition expected.h:1199
Define commit metrics and reports.
Define symbol visibility macros for core Iceberg APIs.
Core Apache Iceberg C++ APIs.
Definition arrow_io_util.h:34
ICEBERG_EXPORT std::string_view ToString(Expression::Operation op)
Returns a string representation of an expression operation.
void unreachable() noexcept
Marks a branch the program can never take.
Definition unreachable.h:35
MetricsReportType
The type of a metrics report.
Definition metrics_reporter.h:40
std::variant< ScanReport, CommitReport > MetricsReport
A metrics report, which can be either a ScanReport or CommitReport.
Definition metrics_reporter.h:60
ICEBERG_EXPORT MetricsReportType GetReportType(const MetricsReport &report)
Get the type of a metrics report.
Definition metrics_reporter.h:66
Define Result, Status, and error helpers.
Define scan metrics and reports.
Portable stand-in for std::unreachable.