Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 3.9k
[fix](segment cache) estimate momory consumed by segment (#35647)#35751
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
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -39,6 +39,8 @@ | ||
| namespace doris { | ||
| struct uint24_t; | ||
| static bvar::Adder<size_t> g_zone_map_memory_bytes("doris_zone_map_memory_bytes"); | ||
| namespace segment_v2 { | ||
| template <PrimitiveType Type> | ||
| @@ -173,9 +175,18 @@ Status ZoneMapIndexReader::_load(bool use_page_cache, bool kept_in_memory, | ||
| return Status::Corruption("Failed to parse zone map"); | ||
| } | ||
| } | ||
| g_zone_map_memory_bytes << sizeof(*this) + sizeof(ZoneMapPB) * _page_zone_maps.size() + | ||
| sizeof(IndexedColumnMetaPB); | ||
| return Status::OK(); | ||
| } | ||
| ZoneMapIndexReader::~ZoneMapIndexReader() { | ||
Contributor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. warning: use '= default' to define a trivial destructor [modernize-use-equals-default] ZoneMapIndexReader::~ZoneMapIndexReader() {
^ | ||
| // Maybe wrong due to load failures. | ||
| g_zone_map_memory_bytes << -sizeof(*this) - sizeof(ZoneMapPB) * _page_zone_maps.size() - | ||
| sizeof(IndexedColumnMetaPB); | ||
| } | ||
| #define APPLY_FOR_PRIMITITYPE(M) \ | ||
| M(TYPE_TINYINT) \ | ||
| M(TYPE_SMALLINT) \ | ||
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.
warning: use '= default' to define a trivial destructor [modernize-use-equals-default]
OrdinalIndexReader::~OrdinalIndexReader() { ^