Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Part of #41.
Abstract the stats counting using ProxyHandlerStats.
This is similar to the implementation inTrino, see: CallStats.java
Add airlift stats in parallel with io.dropwizard.metrics.
Can't remove io.dropwizard.metrics right now because we can't export airlift stats in REST API under Dropwizard.
After switch to Airlift,
ProxyHandlerStats
andCounterStat
will stay.com.codahale.metrics.Meter
andEnvironment
will be gone.JMX can be accessed using RMI (by jconsole or jvisualvm).
![image](https://private-user-images.githubusercontent.com/2330687/320736651-dafb0222-69a6-43e5-a336-aebc48820064.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjUwNjg5NDcsIm5iZiI6MTcyNTA2ODY0NywicGF0aCI6Ii8yMzMwNjg3LzMyMDczNjY1MS1kYWZiMDIyMi02OWE2LTQzZTUtYTMzNi1hZWJjNDg4MjAwNjQucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDgzMSUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA4MzFUMDE0NDA3WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9ZDQyZDYwYzIzMmYxNTQwMDFhNjgwNTYyYzZhMjliZDI5MDNkNmVjM2M5OTE1OGU4NTIxOTUxMTAzZTc0ZmYzOSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.d4UX0XiGAbkdSuBTePWc6uWuquPiG6k1CsMmcPgEQeg)
Airlift stats (new):
Dropwizard metrics (existing):
![image](https://private-user-images.githubusercontent.com/2330687/320736604-0f0448a2-548a-46ee-b4e1-b1df34490ced.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjUwNjg5NDcsIm5iZiI6MTcyNTA2ODY0NywicGF0aCI6Ii8yMzMwNjg3LzMyMDczNjYwNC0wZjA0NDhhMi01NDhhLTQ2ZWUtYjRlMS1iMWRmMzQ0OTBjZWQucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDgzMSUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA4MzFUMDE0NDA3WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9YTBiMDEzODgzMWEwZGI2NDk2MWQ4N2UwZWI5NDFiN2U3MGUxNWU3NzgyNzRmZjEwMjYyNThiM2U4YjQ5M2I4NyZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.-gCkRVTcfvZdx-LNLkzeejLvEfa8X3pV90awbyBQVjE)
Release notes
(x) This is not user-visible or is docs only, and no release notes are required.