Skip to content

Commit

Permalink
[Chore](log) set some variable's fuzzy to true and display inited for…
Browse files Browse the repository at this point in the history
… bf func check (#44752)

### What problem does this PR solve?
 set some variable's fuzzy to true and display inited for bf func check
  • Loading branch information
BiteTheDDDDt authored Nov 28, 2024
1 parent 51ad321 commit 9a36224
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
14 changes: 7 additions & 7 deletions be/src/exprs/bloom_filter_func.h
Original file line number Diff line number Diff line change
Expand Up @@ -157,19 +157,18 @@ class BloomFilterFuncBase : public RuntimeFilterFuncBase {
return Status::InternalError("bloomfilter_func is nullptr");
}
if (bloomfilter_func->_bloom_filter == nullptr) {
return Status::InternalError("bloomfilter_func->_bloom_filter is nullptr");
return Status::InternalError(
"bloomfilter_func->_bloom_filter is nullptr, bloomfilter_func->inited: {}",
bloomfilter_func->_inited);
}
// If `_inited` is false, there is no memory allocated in bloom filter and this is the first
// call for `merge` function. So we just reuse this bloom filter, and we don't need to
// allocate memory again.
if (!_inited) {
auto* other_func = static_cast<BloomFilterFuncBase*>(bloomfilter_func);
if (_bloom_filter != nullptr) {
return Status::InternalError("_bloom_filter must is nullptr");
return Status::InternalError("_bloom_filter must is nullptr, inited: {}", _inited);
}
_bloom_filter = bloomfilter_func->_bloom_filter;
_bloom_filter_alloced = other_func->_bloom_filter_alloced;
_inited = true;
light_copy(bloomfilter_func);
return Status::OK();
}
auto* other_func = static_cast<BloomFilterFuncBase*>(bloomfilter_func);
Expand Down Expand Up @@ -207,7 +206,8 @@ class BloomFilterFuncBase : public RuntimeFilterFuncBase {

bool contain_null() const {
if (!_bloom_filter) {
throw Exception(ErrorCode::INTERNAL_ERROR, "_bloom_filter is nullptr");
throw Exception(ErrorCode::INTERNAL_ERROR, "_bloom_filter is nullptr, inited: {}",
_inited);
}
return _bloom_filter->contain_null();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1202,10 +1202,10 @@ public enum IgnoreSplitType {
@VariableMgr.VarAttr(name = RUNTIME_FILTER_TYPE, fuzzy = true, needForward = true)
private int runtimeFilterType = 12;

@VariableMgr.VarAttr(name = RUNTIME_FILTER_MAX_IN_NUM, needForward = true)
@VariableMgr.VarAttr(name = RUNTIME_FILTER_MAX_IN_NUM, needForward = true, fuzzy = true)
private int runtimeFilterMaxInNum = 1024;

@VariableMgr.VarAttr(name = ENABLE_SYNC_RUNTIME_FILTER_SIZE, needForward = true)
@VariableMgr.VarAttr(name = ENABLE_SYNC_RUNTIME_FILTER_SIZE, needForward = true, fuzzy = true)
private boolean enableSyncRuntimeFilterSize = true;

@VariableMgr.VarAttr(name = ENABLE_PARALLEL_RESULT_SINK, needForward = true, fuzzy = true)
Expand Down Expand Up @@ -1456,7 +1456,7 @@ public void setEnableLeftZigZag(boolean enableLeftZigZag) {
@VariableMgr.VarAttr(name = BROADCAST_HASHTABLE_MEM_LIMIT_PERCENTAGE, needForward = true)
private double broadcastHashtableMemLimitPercentage = 0.2;

@VariableMgr.VarAttr(name = ENABLE_RUNTIME_FILTER_PRUNE, needForward = true)
@VariableMgr.VarAttr(name = ENABLE_RUNTIME_FILTER_PRUNE, needForward = true, fuzzy = true)
public boolean enableRuntimeFilterPrune = true;

/**
Expand Down

0 comments on commit 9a36224

Please sign in to comment.