[ 
https://issues.apache.org/jira/browse/SENTRY-477?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sravya Tirukkovalur updated SENTRY-477:
---------------------------------------
    Attachment: SENTRY-477.WIP.patch

Attaching a WIP patch which generates timer metrics for each meta data 
modifying thrift operation, that is create role, drop role, grant, revoke etc.

Console reporter or JMX reporter can be configured using Sentry property 
"sentry.service.reporting" to either "console" or "jmx". Following is the 
information exposed by timer metrics of codahale:

{noformat}
-- Timers ----------------------------------------------------------------------
org.apache.sentry.provider.db.service.thrift.SentryPolicyStoreProcessor.create-role
             count = 3
         mean rate = 0.22 calls/second
     1-minute rate = 0.05 calls/second
     5-minute rate = 0.01 calls/second
    15-minute rate = 0.00 calls/second
               min = 7.77 milliseconds
               max = 1290.52 milliseconds
              mean = 431.19 milliseconds
            stddev = 603.10 milliseconds
            median = 8.06 milliseconds
              75% <= 1290.52 milliseconds
              95% <= 1290.52 milliseconds
              98% <= 1290.52 milliseconds
              99% <= 1290.52 milliseconds
            99.9% <= 1290.52 milliseconds
org.apache.sentry.provider.db.service.thrift.SentryPolicyStoreProcessor.drop-role
             count = 2
         mean rate = 0.15 calls/second
     1-minute rate = 0.00 calls/second
     5-minute rate = 0.00 calls/second
    15-minute rate = 0.00 calls/second
               min = 10.51 milliseconds
               max = 28.83 milliseconds
              mean = 19.60 milliseconds
            stddev = 9.16 milliseconds
            median = 10.51 milliseconds
              75% <= 28.83 milliseconds
              95% <= 28.83 milliseconds
              98% <= 28.83 milliseconds
              99% <= 28.83 milliseconds
            99.9% <= 28.83 milliseconds
org.apache.sentry.provider.db.service.thrift.SentryPolicyStoreProcessor.grant-privilege
             count = 6
         mean rate = 0.44 calls/second
     1-minute rate = 0.02 calls/second
     5-minute rate = 0.00 calls/second
    15-minute rate = 0.00 calls/second
               min = 7.31 milliseconds
               max = 45.55 milliseconds
              mean = 24.32 milliseconds
            stddev = 13.45 milliseconds
            median = 20.04 milliseconds
              75% <= 38.85 milliseconds
              95% <= 45.55 milliseconds
              98% <= 45.55 milliseconds
              99% <= 45.55 milliseconds
            99.9% <= 45.55 milliseconds
{noformat}

It mainly exposes rates of each operation, and a histogram of time taken to 
serve the request, which can be useful for monitoring purposes. [~lskuff], 
[~prasadm]: any suggestions on what other metrics would be good to capture? I 
was also planning to 
- Add some timers to jdo layer to get a sense of what % of time is being spent 
in jdo operations in the entire thrift call. 
- Also add the timer metrics for non meta data modifying thrift calls.

> Sentry service should expose metrics
> ------------------------------------
>
>                 Key: SENTRY-477
>                 URL: https://issues.apache.org/jira/browse/SENTRY-477
>             Project: Sentry
>          Issue Type: New Feature
>    Affects Versions: 1.4.0
>            Reporter: Sravya Tirukkovalur
>            Assignee: Sravya Tirukkovalur
>             Fix For: 1.5.0
>
>         Attachments: SENTRY-477.WIP.patch
>
>
> It would be good to have Sentry service expose some metrics for both 
> performance testing and monitoring purposes. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to