Appends the saved objects documents count to the CoreUsageData service#124308
Merged
TinaHeiligers merged 6 commits intoelastic:mainfrom Feb 3, 2022
Merged
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves #120485
This PR adds the actually saved objects document count to the
CoreUsageDataServicepayload, retaining the original Lucene document count and other information about the store size from theGET _cat/indices/.kibanaAPI.In addition, this PR adds debug level logs for the Lucene document count and the saved objects documents count to make debugging easier.
Why not just change what we report?
I decided to keep the original payload and add the additional information rather than replace the docs count for 2 reasons:
_cat/indices/.kibana API. It would be confusing to simply replace the lucene docs count with that of the saved objects docs count because that's not what the_cat/indices/.kibana APIAPI returns.Changes:
In the example data payload (Advanced settings -> Usage Data -> cluster data:
In the logs
Logging configuration
Logs
How to test this:
core-usage-stats-serviceinkibana.ymlas described abovecluster statsto see an example of the data Kibana collectssavedObjectsunderservicesin the flyout and observe that we report thesavedObjectsDocsCountas another entry per index.core-usage-stats-servicelogs and observe we have two entries for docs counts: one for the Lucene document count and one for the saved objects document counts.Checklist
Risk Matrix
For maintainers