Jackie-Jiang commented on code in PR #19872:
URL: https://github.com/apache/pinot/pull/19872#discussion_r4277925226
##########
pinot-spi/src/main/java/org/apache/pinot/spi/utils/CommonConstants.java:
##########
@@ -49,9 +49,7 @@ private CommonConstants() {
public static final String CONFIG_OF_BROKER_EVENT_LISTENER_CLASS_NAME =
"factory.className";
public static final String CONFIG_OF_REQUEST_CONTEXT_TRACKED_HEADER_KEYS =
"request.context.tracked.header.keys";
public static final String DEFAULT_METRICS_FACTORY_CLASS_NAME =
- //"org.apache.pinot.plugin.metrics.compound.CompoundPinotMetricsFactory";
- "org.apache.pinot.plugin.metrics.yammer.YammerMetricsFactory";
- //"org.apache.pinot.plugin.metrics.dropwizard.DropwizardMetricsFactory";
+ "org.apache.pinot.plugin.metrics.dropwizard.DropwizardMetricsFactory";
Review Comment:
[P1] Bound timer reservoirs before switching the default
The default switch activates `DropwizardMetricsRegistry.newTimer()`, which
uses `SlidingTimeWindowArrayReservoir(15, TimeUnit.MINUTES)` and retains every
observation for 15 minutes, whereas Yammer caps its reservoir at 1,028 samples.
At 10,000 updates/sec, one timer retains nine million timestamp/value pairs—at
least 144 MB before overhead. Each successful broker query updates table,
global, and workload timers
(`BaseSingleStageBrokerRequestHandler.java:1076–1081`), plus phase timers. JMX
reads also repeatedly copy and sort these populations for individual statistics
and percentiles. This materially increases heap usage and scrape costs for
existing deployments.
Please use a bounded reservoir, such as Dropwizard's exponentially decaying
reservoir, before enabling this backend by default.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]