Skip to content

Commit

Permalink
Emit Metrics for Broker Adaptive Server Selector type (#12482)
Browse files Browse the repository at this point in the history
  • Loading branch information
MeihanLi authored Feb 23, 2024
1 parent efd7786 commit 59551e4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,9 @@ public void start()
_brokerConf.getProperty(Broker.CONFIG_OF_ALLOWED_TABLES_FOR_EMITTING_METRICS, Collections.emptyList()));
_brokerMetrics.initializeGlobalMeters();
_brokerMetrics.setValueOfGlobalGauge(BrokerGauge.VERSION, PinotVersion.VERSION_METRIC_NAME, 1);
_brokerMetrics.setValueOfGlobalGauge(BrokerGauge.ADAPTIVE_SERVER_SELECTOR_TYPE,
_brokerConf.getProperty(Broker.AdaptiveServerSelector.CONFIG_OF_TYPE,
Broker.AdaptiveServerSelector.DEFAULT_TYPE), 1);
BrokerMetrics.register(_brokerMetrics);
// Set up request handling classes
_serverRoutingStatsManager = new ServerRoutingStatsManager(_brokerConf, _brokerMetrics);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,12 @@ public enum BrokerGauge implements AbstractMetrics.Gauge {
NETTY_POOLED_THREADLOCALCACHE("bytes", true),
NETTY_POOLED_CHUNK_SIZE("bytes", true),

/**
* The type of Adaptive Server Selector.
* See {@link org.apache.pinot.spi.utils.CommonConstants.Broker.AdaptiveServerSelector.Type}
*/
ADAPTIVE_SERVER_SELECTOR_TYPE("adaptiveServerSelectorType", true),

/**
* The queue size of ServerRoutingStatsManager main executor service.
*/
Expand Down

0 comments on commit 59551e4

Please sign in to comment.