summaryrefslogtreecommitdiffstats
path: root/searchcore
diff options
context:
space:
mode:
authorGeir Storli <geirst@yahooinc.com>2023-11-10 13:24:09 +0000
committerGeir Storli <geirst@yahooinc.com>2023-11-10 13:24:09 +0000
commit4bbbc7c9e6751cfd888778a3ec192d01d732e895 (patch)
tree1030c7ebdc0c91b3e8f328d1e3945885168a5efa /searchcore
parent83b1ccd36dd5df2e43307aab19adc07b41c94c9f (diff)
More detailed posting store memory usage in attribute explorer.
Diffstat (limited to 'searchcore')
-rw-r--r--searchcore/src/vespa/searchcore/proton/attribute/attribute_vector_explorer.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/attribute/attribute_vector_explorer.cpp b/searchcore/src/vespa/searchcore/proton/attribute/attribute_vector_explorer.cpp
index e801e6f3706..8f75ddd1315 100644
--- a/searchcore/src/vespa/searchcore/proton/attribute/attribute_vector_explorer.cpp
+++ b/searchcore/src/vespa/searchcore/proton/attribute/attribute_vector_explorer.cpp
@@ -100,7 +100,12 @@ convertChangeVectorToSlime(const AttributeVector &v, Cursor &object)
void
convertPostingBaseToSlime(const IPostingListAttributeBase &postingBase, Cursor &object)
{
- convertMemoryUsageToSlime(postingBase.getMemoryUsage(), object.setObject("memoryUsage"));
+ auto& cursor = object.setObject("memory_usage");
+ auto memory_usage = postingBase.getMemoryUsage();
+ convertMemoryUsageToSlime(memory_usage.total, cursor.setObject("total"));
+ convertMemoryUsageToSlime(memory_usage.btrees, cursor.setObject("btrees"));
+ convertMemoryUsageToSlime(memory_usage.short_arrays, cursor.setObject("short_arrays"));
+ convertMemoryUsageToSlime(memory_usage.bitvectors, cursor.setObject("bitvectors"));
}
vespalib::string
@@ -173,7 +178,7 @@ AttributeVectorExplorer::get_state_helper(const AttributeVector& attr, const ves
}
const IPostingListAttributeBase *postingBase = attr.getIPostingListAttributeBase();
if (postingBase) {
- convertPostingBaseToSlime(*postingBase, object.setObject("postingList"));
+ convertPostingBaseToSlime(*postingBase, object.setObject("posting_store"));
}
const auto* tensor_attr = attr.asTensorAttribute();
if (tensor_attr) {