[
https://issues.apache.org/jira/browse/RATIS-1885?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17763293#comment-17763293
]
Wei-Chiu Chuang commented on RATIS-1885:
----------------------------------------
Before the fix:
{noformat}
{
"name":
"ratis:name=ratis.server.3b314415-9809-45cf-900c-9d29e0a28559@group-F3311A5E9171.clientWriteRequest",
"modelerType": "com.codahale.metrics.JmxReporter$JmxTimer",
"50thPercentile": 0.000339,
"DurationUnit": "milliseconds",
"Min": 0.00016999999999999999,
"75thPercentile": 0.00043,
"95thPercentile": 0.000771,
"98thPercentile": 0.001049,
"99thPercentile": 0.001179,
"999thPercentile": 0.0014659999999999999,
"Max": 0.001469,
"Mean": 0.00040126083976232567,
"StdDev": 0.00019045465920954606,
"RateUnit": "events/second",
"Count": 1317,
"FifteenMinuteRate": 1.4704070704560734,
"OneMinuteRate": 15.706691001210936,
"MeanRate": 24.80257716381477,
"FiveMinuteRate": 3.897188059034412
},
{noformat}
After fix:
{noformat}
{
"name":
"ratis:name=ratis.server.e915e8d3-489b-4e1b-a7b9-1da6c5454519@group-9328653D0CB0.clientWriteRequest",
"modelerType": "com.codahale.metrics.JmxReporter$JmxTimer",
"Min": 5.788385,
"75thPercentile": 22.560859999999998,
"95thPercentile": 36.773108,
"98thPercentile": 48.900596,
"99thPercentile": 54.580382,
"999thPercentile": 56.013548,
"Max": 56.013548,
"Mean": 16.836746432206215,
"StdDev": 11.311347869033634,
"50thPercentile": 11.054679,
"DurationUnit": "milliseconds",
"FifteenMinuteRate": 0,
"FiveMinuteRate": 0,
"OneMinuteRate": 0,
"MeanRate": 40.86386097430851,
"Count": 114,
"RateUnit": "events/second"
},
{noformat}
> Incorrect clientWriteRequest timer
> ----------------------------------
>
> Key: RATIS-1885
> URL: https://issues.apache.org/jira/browse/RATIS-1885
> Project: Ratis
> Issue Type: Bug
> Components: metrics
> Affects Versions: 2.5.1
> Reporter: Wei-Chiu Chuang
> Priority: Major
>
> clientWriteRequest timer measures the time from receiving the client request
> until the leader responds back.
> But this timer is only initialized when the leader responds, so the timer is
> always close to zero.
> https://github.com/apache/ratis/blob/branch-2/ratis-server/src/main/java/org/apache/ratis/server/impl/RaftServerImpl.java#L840
> The bug is accidentally fixed in 3.0.0 by RATIS-1693. But for users of 2.x
> this may still be worth fixing.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)