adutra commented on code in PR #3468:
URL: https://github.com/apache/polaris/pull/3468#discussion_r2703899483
##########
runtime/service/src/main/java/org/apache/polaris/service/catalog/iceberg/IcebergRestCatalogEventServiceDelegator.java:
##########
@@ -805,8 +810,41 @@ public Response reportMetrics(
ReportMetricsRequest reportMetricsRequest,
RealmContext realmContext,
SecurityContext securityContext) {
- return delegate.reportMetrics(
- prefix, namespace, table, reportMetricsRequest, realmContext,
securityContext);
+ // Check if metrics event emission is enabled
+ boolean metricsEventEmissionEnabled =
+
realmConfig.getConfig(FeatureConfiguration.ENABLE_METRICS_EVENT_EMISSION);
+
+ // If metrics event emission is disabled, call delegate directly without
emitting events
+ if (!metricsEventEmissionEnabled) {
Review Comment:
This is probably going to conflict a bit with #3442. The idea there is that
events would only be emitted if there is interest for them from the listener(s).
I don't think creating a feature configuration for each event type would
scale out well.
--
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]