Abhishek Rawat has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/24283 )

Change subject: IMPALA-14962: Query Profile Parser and Section Retrieval 
Interface
......................................................................


Patch Set 12:

(3 comments)

http://gerrit.cloudera.org:8080/#/c/24283/11/be/src/service/query-profile-parsing-tools.cc
File be/src/service/query-profile-parsing-tools.cc:

http://gerrit.cloudera.org:8080/#/c/24283/11/be/src/service/query-profile-parsing-tools.cc@121
PS11, Line 121:   const int64_t process_mem_limit = 
exec_env->process_mem_tracker()->limit();
We could compute and cache the default limit at the first invocation:
```
  static const int64_t cached_limit = [&]() {
    const int64_t process_mem_limit = exec_env->process_mem_tracker()->limit();
    if (process_mem_limit <= 0) return 
DEFAULT_PARSING_PROFILE_SIZE_LIMIT_MAX_BYTES;

    int64_t percentage_limit_bytes = static_cast<int64_t>(
        DEFAULT_PARSING_PROFILE_SIZE_LIMIT_PERCENTAGE / 100.0 * 
process_mem_limit);
    percentage_limit_bytes = std::max<int64_t>(1L, percentage_limit_bytes);

    return std::min(DEFAULT_PARSING_PROFILE_SIZE_LIMIT_MAX_BYTES, 
percentage_limit_bytes);
  }();

  return cached_limit;
```

Maybe also add same logic in the redaction module?


http://gerrit.cloudera.org:8080/#/c/24283/11/be/src/service/query-profile-parsing-tools.cc@395
PS11, Line 395:     string_view fragment_id, Document::AllocatorType& alloc) 
const {
Should we make the logic deterministic? Basically `GetFragment` returns the Avg 
Fragment and GetFragmentInstances returns all the instances for that fragment? 
That way we don't need to rely on scoring and  the logic could first look at 
avg fragments followed by individual fragment instances as needed.


http://gerrit.cloudera.org:8080/#/c/24283/11/be/src/service/query-profile-parsing-tools.cc@486
PS11, Line 486:     Document::AllocatorType& alloc) const {
Wondering why is there a GetScanNodesSummary() and not generic 
GetNodesSummary(nodeId) ?



--
To view, visit http://gerrit.cloudera.org:8080/24283
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4d9c9e735aa089bb243b07af421553002a465a88
Gerrit-Change-Number: 24283
Gerrit-PatchSet: 12
Gerrit-Owner: Gokul Kolady <[email protected]>
Gerrit-Reviewer: Abhishek Rawat <[email protected]>
Gerrit-Reviewer: Gokul Kolady <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Jason Fehr <[email protected]>
Gerrit-Reviewer: Yida Wu <[email protected]>
Gerrit-Comment-Date: Mon, 18 May 2026 22:23:24 +0000
Gerrit-HasComments: Yes

Reply via email to