-
Notifications
You must be signed in to change notification settings - Fork 305
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HPCC-33279 Serve CKeyBuilder stats through getStatistic #19442
base: master
Are you sure you want to change the base?
Conversation
Jira Issue: https://hpccsystems.atlassian.net//browse/HPCC-33279 Jirabot Action Result: |
2cc1f12
to
1ca7faf
Compare
Jira Issue: https://hpccsystems.atlassian.net//browse/HPCC-33279 Jirabot Action Result: |
- Serve CKeyBuilder statistics through getStatistic - the standard method of serving statistics. - Publish 4 new statistics for index write activity: StNumDuplicateKeyCount, StNumOffsetBranches, StSizeBranchMemory and StSizeLeafMemory. Signed-off-by: Shamser Ahmed <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@shamser - 1 minor issue.
system/jlib/jstats.cpp
Outdated
@@ -999,6 +999,11 @@ static const constexpr StatisticMeta statsMetaData[StMax] = { | |||
{ PEAKNUMSTAT(PeakCacheObjects), "High water mark for number of objects in a cache"}, | |||
{ NUMSTAT(CacheDuplicates), "The number of times an item was added to a cache by two threads at the same time" }, | |||
{ NUMSTAT(CacheEvictions), "The number of times an item was evicted from a cache" }, | |||
{ NUMSTAT(DuplicateKeyCount), "The number of duplicate keys" }, | |||
{ NUMSTAT(OffsetBranches), "The number of offset branches" }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a number of offset branches - it is the [single] offset into the index where the branch nodes starts (vs the leaf nodes). So I think this should be SIZESTAT and description something like "The 1st branch node offset position in the index"
mb.append(branchMemorySize); | ||
mb.append(leafMemorySize); | ||
mb.append(inactiveStats.getStatisticValue(StSizeBranchMemory)); | ||
mb.append(inactiveStats.getStatisticValue(StSizeLeafMemory)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these stats are now already being serialized to the manager (via regular stats. serialization),
so I think these lines should be deleted, and the corresponding manual deserialization in the manager activity code, and the manager activity should pick up these values from CMasterActivity::statsCollection..
e.g. in IndexWriteActivityMaster::done:
props.setPropInt64("@numLeafNodes", statsCollection.getStatisticSum(StNumLeafCacheAdds));
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not urgent, so can be left to a subsequent JIRA/PR if you prefer?
Should be a relatively easy change and avoid future confusion re. 2 places these stats. are serialized/deserialized.
Signed-off-by: Shamser Ahmed <[email protected]>
Type of change:
Checklist:
Smoketest:
Testing: