[ 
https://issues.apache.org/jira/browse/OAK-7384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16423897#comment-16423897
 ] 

Michael Dürig commented on OAK-7384:
------------------------------------

Patch looks good re. the implemented changes. I have a few comments wrt. 
implementation details:

* {{SegmentNodeStoreStats#setCollectStackTraces}} to be consistent with the 
other method that change the configuration of the commit tracker, I would also 
make this flag immutable and acquire a new {{CommitsTracker}} when toggled. 
* Consider implementing {{Closeable} in {{CommitsTracker}}
* {{CommitsTracker#commitsCountPerThreadGroupLastMinute}} should wither be 
volatile or final holding a reference to a thread safe map that is cleared 
instead of re-intantiated.
* {{CommitsTracker#CommitsTracker}}: the call to {{format}} when scheduling the 
background task does not take any arguments after the format string. 
* The name {{SegmentNodeStoreStatsMBean#setCommitsCountMapMaxSize}} refers to 
the implementation. I would prefer a name that is more descriptive to the user. 
* Similar for {{SegmentNodeStoreStatsMBean#set/getThreadGroups}}: I would 
prefer a name that make it easier to relate to 
{{getCommitsCountPerGroupLastMinute}}.

> SegmentNodeStoreStats should expose stats for previous minute per thread group
> ------------------------------------------------------------------------------
>
>                 Key: OAK-7384
>                 URL: https://issues.apache.org/jira/browse/OAK-7384
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: segment-tar
>            Reporter: Andrei Dulceanu
>            Assignee: Andrei Dulceanu
>            Priority: Minor
>              Labels: tooling
>             Fix For: 1.9.0, 1.10
>
>         Attachments: OAK-7384.patch
>
>
> The current "CommitsCountPerWriter" stats exposed by 
> {{SegmentNodeStoreStats}} are hard to follow since there can be too many 
> writers at a time. To improve this, a more coarse-grained version of this 
> metric should be added, in which commits are recorded for groups of threads. 
> The groups should be configurable and represent regexes to be matched by 
> individual thread names. An additional group (i.e. "other") will group all 
> threads not matching any of the defined group regexes. 
> The current behaviour will be split in two:
> * "CommitsCountOtherThreads" will expose a snapshot of threads currently in 
> "other" group
> * "CommitsCountPerGroup" will expose an aggregate of commits count per thread 
> group for the previous minute.
> Both metrics will be reset each minute.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to