Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriel39 committed Jan 30, 2024
1 parent b238d39 commit bbda42c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions be/src/pipeline/exec/olap_scan_operator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ Status OlapScanLocalState::_init_profile() {
_filtered_segment_counter = ADD_COUNTER(_segment_profile, "NumSegmentFiltered", TUnit::UNIT);
_total_segment_counter = ADD_COUNTER(_segment_profile, "NumSegmentTotal", TUnit::UNIT);
_tablet_counter = ADD_COUNTER(_runtime_profile, "TabletNum", TUnit::UNIT);
_key_range_counter = ADD_COUNTER(_runtime_profile, "KeyRangesNum", TUnit::UNIT);
_runtime_filter_info = ADD_LABEL_COUNTER_WITH_LEVEL(_runtime_profile, "RuntimeFilterInfo", 1);
return Status::OK();
}
Expand Down Expand Up @@ -323,6 +324,7 @@ Status OlapScanLocalState::_init_scanners(std::list<vectorized::VScannerSPtr>* s

auto build_new_scanner = [&](BaseTabletSPtr tablet, int64_t version,
const std::vector<OlapScanRange*>& key_ranges) {
COUNTER_UPDATE(_key_range_counter, key_ranges.size());
auto scanner = vectorized::NewOlapScanner::create_shared(
this, vectorized::NewOlapScanner::Params {
state(),
Expand Down
1 change: 1 addition & 0 deletions be/src/pipeline/exec/olap_scan_operator.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ class OlapScanLocalState final : public ScanLocalState<OlapScanLocalState> {
RuntimeProfile::Counter* _num_disks_accessed_counter = nullptr;

RuntimeProfile::Counter* _tablet_counter = nullptr;
RuntimeProfile::Counter* _key_range_counter = nullptr;
RuntimeProfile::Counter* _rows_pushed_cond_filtered_counter = nullptr;
RuntimeProfile::Counter* _reader_init_timer = nullptr;
RuntimeProfile::Counter* _scanner_init_timer = nullptr;
Expand Down
2 changes: 2 additions & 0 deletions be/src/vec/exec/scan/new_olap_scan_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ Status NewOlapScanNode::prepare(RuntimeState* state) {
// if you want to add some profile in scan node, even it have not new VScanner object
// could add here, not in the _init_profile() function
_tablet_counter = ADD_COUNTER(_runtime_profile, "TabletNum", TUnit::UNIT);
_key_range_counter = ADD_COUNTER(_runtime_profile, "KeyRangesNum", TUnit::UNIT);
return Status::OK();
}

Expand Down Expand Up @@ -594,6 +595,7 @@ Status NewOlapScanNode::_init_scanners(std::list<VScannerSPtr>* scanners) {
auto build_new_scanner = [&](BaseTabletSPtr tablet, int64_t version,
const std::vector<OlapScanRange*>& key_ranges,
TabletReader::ReadSource read_source) {
COUNTER_UPDATE(_key_range_counter, key_ranges.size());
auto scanner =
NewOlapScanner::create_shared(this, NewOlapScanner::Params {
_state,
Expand Down
1 change: 1 addition & 0 deletions be/src/vec/exec/scan/new_olap_scan_node.h
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ class NewOlapScanNode : public VScanNode {
RuntimeProfile::Counter* _num_disks_accessed_counter = nullptr;

RuntimeProfile::Counter* _tablet_counter = nullptr;
RuntimeProfile::Counter* _key_range_counter = nullptr;
RuntimeProfile::Counter* _rows_pushed_cond_filtered_counter = nullptr;
RuntimeProfile::Counter* _reader_init_timer = nullptr;
RuntimeProfile::Counter* _scanner_init_timer = nullptr;
Expand Down

0 comments on commit bbda42c

Please sign in to comment.