[
https://issues.apache.org/jira/browse/RANGER-4196?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17757450#comment-17757450
]
Vikas Kumar edited comment on RANGER-4196 at 8/22/23 1:07 PM:
--------------------------------------------------------------
Hi,
Review request raised: [https://reviews.apache.org/r/74557/]
Testing:
build is passed.
Patched the new jar on existing cluster and tried to fetch the kms metrics.
Following is the output:
command: curl -ivk --negotiate -u : -H "Content-Type: application/json" -X GET
[http://<KMSSERVER>:9292/kms/metrics/json|http://%3Ckmsserver%3E:9292/kms/metrics/json]
Output:
{code:java}
{
"KMS": {
"GET_CURRENT_KEY_COUNT": 0,
"DELETE_KEY_ELAPSED_TIME": 0,
"EEK_DECRYPT_ELAPSED_TIME": 0,
"GET_KEYS_METADATA_ELAPSED_TIME": 0,
"EEK_GENERATE_ELAPSED_TIME": 0,
"GET_CURRENT_KEY_ELAPSED_TIME": 0,
"EEK_REENCRYPT_ELAPSED_TIME": 0,
"KEY_CREATE_COUNT": 0,
"UNAUTHORIZED_CALLS_COUNT": 0,
"KEY_CREATE_ELAPSED_TIME": 0,
"GET_KEY_VERSION_COUNT": 0,
"ROLL_NEW_VERSION_ELAPSED_TIME": 0,
"REENCRYPT_EEK_BATCH_COUNT": 0,
"REENCRYPT_EEK_BATCH_ELAPSED_TIME": 0,
"GET_KEYS_METADATA_COUNT": 0,
"GET_KEY_VERSIONS_COUNT": 0,
"GET_KEY_VERSIONS_ELAPSED_TIME": 0,
"GET_KEYS_COUNT": 0,
"EEK_GENERATE_COUNT": 0,
"INVALIDATE_CACHE_COUNT": 0,
"GET_METADATA_COUNT": 0,
"REENCRYPT_EEK_BATCH_KEYS_COUNT": 0,
"EEK_REENCRYPT_COUNT": 0,
"UNAUTHENTICATED_CALLS_COUNT": 3,
"GET_KEY_VERSION_ELAPSED_TIME": 0,
"INVALIDATE_CACHE_ELAPSED_TIME": 0,
"ROLL_NEW_VERSION_COUNT": 0,
"EEK_DECRYPT_COUNT": 0,
"GET_KEYS_METADATA_KEYNAMES_COUNT": 0,
"DELETE_KEY_COUNT": 0,
"GET_KEYS_ELAPSED_TIME": 0,
"GET_METADATA_ELAPSED_TIME": 0,
"TOTAL_CALL_COUNT": 6
},
"RangerWebContainer": {
"ActiveConnectionsCount": 2,
"ConnectionTimeout": 60000,
"MaxWorkerThreadsCount": 200,
"TotalWorkerThreadsCount": 10,
"KeepAliveTimeout": 60000,
"ActiveWorkerThreadsCount": 0,
"ConnectionAcceptCount": 100,
"MinSpareWorkerThreadsCount": 10,
"MaxConnectionsCount": 8192
},
"RangerJvm": {
"GcTimeTotal": 595,
"SystemLoadAvg": 10.21,
"ThreadsBusy": 5,
"GcCountTotal": 17,
"MemoryMax": 967311360,
"MemoryCurrent": 273806280,
"ThreadsWaiting": 17,
"ProcessorsAvailable": 4,
"GcTimeMax": 595,
"ThreadsBlocked": 0,
"ThreadsRemaining": 16
}
} {code}
Knowing the Tomcat connector type is also useful, so logged following on
container startup.
2023-08-22 12:43:45,080 INFO org.apache.ranger.server.tomcat.EmbeddedServer:
[vktomcat-1.vktomcat.\{*}_*_\{*}*-startStop-1]: Selected Tomcat
protocolHandler: "http-nio-9292"
was (Author: JIRAUSER295683):
Hi,
Review request raised: [https://reviews.apache.org/r/74557/]
Testing:
build is passed.
Patched the new jar on existing cluster and tried to fetch the kms metrics.
Following is the output:
command: curl -ivk --negotiate -u : -H "Content-Type: application/json" -X GET
[http://<KMSSERVER>:9292/kms/metrics/json|http://%3Ckmsserver%3E:9292/kms/metrics/json]
Output:
{
"KMS": \{
"GET_CURRENT_KEY_COUNT": 0,
"DELETE_KEY_ELAPSED_TIME": 0,
"EEK_DECRYPT_ELAPSED_TIME": 0,
"GET_KEYS_METADATA_ELAPSED_TIME": 0,
"EEK_GENERATE_ELAPSED_TIME": 0,
"GET_CURRENT_KEY_ELAPSED_TIME": 0,
"EEK_REENCRYPT_ELAPSED_TIME": 0,
"KEY_CREATE_COUNT": 0,
"UNAUTHORIZED_CALLS_COUNT": 0,
"KEY_CREATE_ELAPSED_TIME": 0,
"GET_KEY_VERSION_COUNT": 0,
"ROLL_NEW_VERSION_ELAPSED_TIME": 0,
"REENCRYPT_EEK_BATCH_COUNT": 0,
"REENCRYPT_EEK_BATCH_ELAPSED_TIME": 0,
"GET_KEYS_METADATA_COUNT": 0,
"GET_KEY_VERSIONS_COUNT": 0,
"GET_KEY_VERSIONS_ELAPSED_TIME": 0,
"GET_KEYS_COUNT": 0,
"EEK_GENERATE_COUNT": 0,
"INVALIDATE_CACHE_COUNT": 0,
"GET_METADATA_COUNT": 0,
"REENCRYPT_EEK_BATCH_KEYS_COUNT": 0,
"EEK_REENCRYPT_COUNT": 0,
"UNAUTHENTICATED_CALLS_COUNT": 3,
"GET_KEY_VERSION_ELAPSED_TIME": 0,
"INVALIDATE_CACHE_ELAPSED_TIME": 0,
"ROLL_NEW_VERSION_COUNT": 0,
"EEK_DECRYPT_COUNT": 0,
"GET_KEYS_METADATA_KEYNAMES_COUNT": 0,
"DELETE_KEY_COUNT": 0,
"GET_KEYS_ELAPSED_TIME": 0,
"GET_METADATA_ELAPSED_TIME": 0,
"TOTAL_CALL_COUNT": 6
},
"RangerWebContainer": \{
"ActiveConnectionsCount": 2,
"ConnectionTimeout": 60000,
"MaxWorkerThreadsCount": 200,
"TotalWorkerThreadsCount": 10,
"KeepAliveTimeout": 60000,
"ActiveWorkerThreadsCount": 0,
"ConnectionAcceptCount": 100,
"MinSpareWorkerThreadsCount": 10,
"MaxConnectionsCount": 8192
},
"RangerJvm": \{
"GcTimeTotal": 595,
"SystemLoadAvg": 10.21,
"ThreadsBusy": 5,
"GcCountTotal": 17,
"MemoryMax": 967311360,
"MemoryCurrent": 273806280,
"ThreadsWaiting": 17,
"ProcessorsAvailable": 4,
"GcTimeMax": 595,
"ThreadsBlocked": 0,
"ThreadsRemaining": 16
}
}
Knowing the Tomcat connector type is also useful, so logged following on
container startup.
2023-08-22 12:43:45,080 INFO org.apache.ranger.server.tomcat.EmbeddedServer:
[vktomcat-1.vktomcat.{*}_*_{*}*-startStop-1]: Selected Tomcat protocolHandler:
"http-nio-9292"
> Tomcat metrics collection
> --------------------------
>
> Key: RANGER-4196
> URL: https://issues.apache.org/jira/browse/RANGER-4196
> Project: Ranger
> Issue Type: Improvement
> Components: Ranger
> Reporter: Vikas Kumar
> Assignee: Vikas Kumar
> Priority: Major
>
> Like "JVM mterics" and other application metrics, Tomcat related metrics
> would be very useful for following use cases:
> In case client gets "SoketTimeout" or Connection refused errors, having such
> metrics at server end will really help triaging the issue.
> It should contain following metrics:
> # maxAllowedConnection
> # currentActiveConnectionCount
> # ConnectionTimeout
> # acceptCount
> # maxContainerThreadsCount
> # activeContainerThreadsCount
> # minSpareThreadsCount // corePoolSize
> And other useful metrics.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)