dimas-b commented on code in PR #4115:
URL: https://github.com/apache/polaris/pull/4115#discussion_r3424422949


##########
runtime/service/src/main/java/org/apache/polaris/service/config/ServiceProducers.java:
##########
@@ -457,9 +457,16 @@ public RequestIdSupplier requestIdSupplier() {
 
   @Produces
   @ApplicationScoped
-  public PolarisMetricsReporter metricsReporter(
-      MetricsReportingConfiguration config, @Any 
Instance<PolarisMetricsReporter> reporters) {
-    return reporters.select(Identifier.Literal.of(config.type())).get();
+  public IcebergMetricsReporter metricsReporter(
+      MetricsReportingConfiguration config, @Any 
Instance<IcebergMetricsReporter> reporters) {
+    var selected = reporters.select(Identifier.Literal.of(config.type()));
+    if (selected.isUnsatisfied()) {
+      LOGGER.warn(
+          "No IcebergMetricsReporter found for type '{}'; Iceberg metrics will 
be dropped",
+          config.type());
+      return (catalogName, catalogId, table, tableId, metricsReport, 
receivedTimestamp) -> {};

Review Comment:
   but `NoOpMetricsReporter` appears to be in `extensions/metrics-reports/impl` 
(not SPI) now?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to