-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
[feat](test) add bloomfilter ut case #44351
Conversation
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
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.
clang-tidy made some suggestions
@@ -295,5 +296,203 @@ TEST_F(BloomFilterIndexReaderWriterTest, test_decimal) { | |||
delete[] val; | |||
} | |||
|
|||
TEST_F(BloomFilterIndexReaderWriterTest, test_datev2) { | |||
size_t num = 1024 * 3 - 1; | |||
uint32_t* val = new uint32_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
uint32_t* val = new uint32_t[num]; | |
auto* val = new uint32_t[num]; |
|
||
TEST_F(BloomFilterIndexReaderWriterTest, test_datetimev2) { | ||
size_t num = 1024 * 3 - 1; | ||
uint64_t* val = new uint64_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
uint64_t* val = new uint64_t[num]; | |
auto* val = new uint64_t[num]; |
|
||
TEST_F(BloomFilterIndexReaderWriterTest, test_decimal32) { | ||
size_t num = 1024 * 3 - 1; | ||
int32_t* val = new int32_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
int32_t* val = new int32_t[num]; | |
auto* val = new int32_t[num]; |
delete[] val; | ||
} | ||
|
||
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values, |
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: function 'test_ngram_bloom_filter_index_reader_writer' exceeds recommended size/complexity thresholds [readability-function-size]
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
Additional context
be/test/olap/rowset/segment_v2/bloom_filter_index_reader_writer_test.cpp:340: 95 lines including whitespace and comments (threshold 80)
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
run buildall |
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.
clang-tidy made some suggestions
TEST_F(BloomFilterIndexReaderWriterTest, test_decimal64) { | ||
size_t num = 1024 * 3 - 1; | ||
; | ||
int64_t* val = new int64_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
int64_t* val = new int64_t[num]; | |
auto* val = new int64_t[num]; |
|
||
TEST_F(BloomFilterIndexReaderWriterTest, test_ipv4) { | ||
size_t num = 1024 * 3 - 1; | ||
uint32_t* val = new uint32_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
uint32_t* val = new uint32_t[num]; | |
auto* val = new uint32_t[num]; |
|
||
TEST_F(BloomFilterIndexReaderWriterTest, test_decimal128i) { | ||
size_t num = 1024 * 3 - 1; | ||
int128_t* val = new int128_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
int128_t* val = new int128_t[num]; | |
auto* val = new int128_t[num]; |
} | ||
|
||
std::string file_name = "bloom_filter_decimal128i"; | ||
int128_t not_exist_value = int128_t(9999999999999999999ULL); |
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 auto when initializing with a cast to avoid duplicating the type name [modernize-use-auto]
int128_t not_exist_value = int128_t(9999999999999999999ULL); | |
auto not_exist_value = int128_t(9999999999999999999ULL); |
|
||
TEST_F(BloomFilterIndexReaderWriterTest, test_ipv6) { | ||
size_t num = 1024 * 3 - 1; | ||
uint128_t* val = new uint128_t[num]; |
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 auto when initializing with new to avoid duplicating the type name [modernize-use-auto]
uint128_t* val = new uint128_t[num]; | |
auto* val = new uint128_t[num]; |
delete[] val; | ||
} | ||
|
||
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values, |
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: function 'test_ngram_bloom_filter_index_reader_writer' exceeds recommended size/complexity thresholds [readability-function-size]
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
Additional context
be/test/olap/rowset/segment_v2/bloom_filter_index_reader_writer_test.cpp:428: 95 lines including whitespace and comments (threshold 80)
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
TPC-H: Total hot run time: 39852 ms
|
TPC-DS: Total hot run time: 196097 ms
|
ClickBench: Total hot run time: 32.61 s
|
TeamCity be ut coverage result: |
d4ed7c8
to
ca998c7
Compare
run buildall |
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.
clang-tidy made some suggestions
delete[] val; | ||
} | ||
|
||
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values, |
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: function 'test_ngram_bloom_filter_index_reader_writer' exceeds recommended size/complexity thresholds [readability-function-size]
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
Additional context
be/test/olap/rowset/segment_v2/bloom_filter_index_reader_writer_test.cpp:477: 95 lines including whitespace and comments (threshold 80)
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
TPC-H: Total hot run time: 40294 ms
|
TPC-DS: Total hot run time: 197316 ms
|
ClickBench: Total hot run time: 32.49 s
|
run buildall |
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.
clang-tidy made some suggestions
delete[] val; | ||
} | ||
|
||
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values, |
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: function 'test_ngram_bloom_filter_index_reader_writer' exceeds recommended size/complexity thresholds [readability-function-size]
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
Additional context
be/test/olap/rowset/segment_v2/bloom_filter_index_reader_writer_test.cpp:485: 95 lines including whitespace and comments (threshold 80)
void test_ngram_bloom_filter_index_reader_writer(const std::string& file_name, Slice* values,
^
TeamCity be ut coverage result: |
TPC-H: Total hot run time: 39573 ms
|
TPC-DS: Total hot run time: 196775 ms
|
ClickBench: Total hot run time: 33.74 s
|
run buildall |
1 similar comment
run buildall |
TPC-H: Total hot run time: 39691 ms
|
TPC-DS: Total hot run time: 196754 ms
|
ClickBench: Total hot run time: 32.73 s
|
TeamCity be ut coverage result: |
run buildall |
TeamCity be ut coverage result: |
TPC-H: Total hot run time: 40063 ms
|
TPC-DS: Total hot run time: 197297 ms
|
TPC-DS: Total hot run time: 198536 ms
|
ClickBench: Total hot run time: 32.95 s
|
run buildall |
TPC-H: Total hot run time: 40303 ms
|
TPC-DS: Total hot run time: 190828 ms
|
ClickBench: Total hot run time: 32.74 s
|
TeamCity be ut coverage result: |
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.
LGTM
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
ebae1c1
to
259f6bb
Compare
run buildall |
TeamCity be ut coverage result: |
TPC-H: Total hot run time: 40064 ms
|
TPC-DS: Total hot run time: 197607 ms
|
ClickBench: Total hot run time: 32.43 s
|
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.
LGTM
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)