dukelion opened a new pull request, #2291: URL: https://github.com/apache/zookeeper/pull/2291
…w client In production environments under heavy load, the existing PrometheusMetricsProvider can introduce high latency. This is largely due to its use of the outdated `io.prometheus.client` (simpleclient 0.x) library and its basic, built-in HTTPServer, which has limitations in server configuration and threading. This commit modernizes the entire component to address these performance and maintainability issues by: 1. **Upgrading to the `io.prometheus.metrics` (client_java 1.x) library.** This aligns the provider with the current standard for Prometheus instrumentation in Java and ensures future compatibility. 2. **Replacing the legacy server and threading model with an embedded Jetty server.** The previous implementation used a custom thread pool for a metrics processing task queue, which is now obsolete in the new client library. This has been replaced with a robust Jetty server, which uses its own configurable thread pool to handle exporter servlet requests directly. This change improves stability and simplifies the threading model, resolving the latency issues under load. These changes make the PrometheusMetricsProvider more stable, performant, maintainable, and easier to configure for production use. -- 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: notifications-unsubscr...@zookeeper.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org