-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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](json) Support json_search function in 2.0 #40962
Conversation
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
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
@@ -357,6 +373,19 @@ class JsonbPath { | |||
leg_vector.emplace_back(leg.release()); |
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 of undeclared identifier 'leg_vector' [clang-diagnostic-error]
leg_vector.emplace_back(leg.release());
^
@@ -357,6 +373,19 @@ | |||
leg_vector.emplace_back(leg.release()); | |||
} | |||
|
|||
void pop_leg_from_leg_vector() { leg_vector.pop_back(); } |
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 of undeclared identifier 'leg_vector' [clang-diagnostic-error]
void pop_leg_from_leg_vector() { leg_vector.pop_back(); }
^
|
||
bool to_string(std::string* res) const { | ||
res->push_back(SCOPE); | ||
for (const auto& leg : leg_vector) { |
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 of undeclared identifier 'leg_vector' [clang-diagnostic-error]
for (const auto& leg : leg_vector) {
^
} | ||
return true; | ||
} | ||
|
||
size_t get_leg_vector_size() { return leg_vector.size(); } |
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 of undeclared identifier 'leg_vector' [clang-diagnostic-error]
size_t get_leg_vector_size() { return leg_vector.size(); }
^
} | ||
return true; | ||
} | ||
|
||
size_t get_leg_vector_size() { return leg_vector.size(); } | ||
|
||
leg_info* get_leg_from_leg_vector(size_t i) { return leg_vector[i].get(); } |
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 of undeclared identifier 'leg_vector' [clang-diagnostic-error]
leg_info* get_leg_from_leg_vector(size_t i) { return leg_vector[i].get(); }
^
static constexpr auto name = "json_search"; | ||
static FunctionPtr create() { return std::make_shared<FunctionJsonSearch>(); } | ||
|
||
String get_name() const override { return name; } |
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 'get_name' should be marked [[nodiscard]] [modernize-use-nodiscard]
String get_name() const override { return name; } | |
[[nodiscard]] String get_name() const override { return name; } |
static FunctionPtr create() { return std::make_shared<FunctionJsonSearch>(); } | ||
|
||
String get_name() const override { return name; } | ||
bool is_variadic() const override { return false; } |
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 'is_variadic' should be marked [[nodiscard]] [modernize-use-nodiscard]
bool is_variadic() const override { return false; } | |
[[nodiscard]] bool is_variadic() const override { return false; } |
|
||
String get_name() const override { return name; } | ||
bool is_variadic() const override { return false; } | ||
size_t get_number_of_arguments() const override { return 0; } |
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 'get_number_of_arguments' should be marked [[nodiscard]] [modernize-use-nodiscard]
size_t get_number_of_arguments() const override { return 0; } | |
[[nodiscard]] size_t get_number_of_arguments() const override { return 0; } |
bool is_variadic() const override { return false; } | ||
size_t get_number_of_arguments() const override { return 0; } | ||
|
||
DataTypePtr get_return_type_impl(const DataTypes& arguments) const override { |
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 'get_return_type_impl' should be marked [[nodiscard]] [modernize-use-nodiscard]
DataTypePtr get_return_type_impl(const DataTypes& arguments) const override { | |
[[nodiscard]] DataTypePtr get_return_type_impl(const DataTypes& arguments) const override { |
return make_nullable(std::make_shared<DataTypeJsonb>()); | ||
} | ||
|
||
bool use_default_implementation_for_nulls() const override { return false; } |
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 'use_default_implementation_for_nulls' should be marked [[nodiscard]] [modernize-use-nodiscard]
bool use_default_implementation_for_nulls() const override { return false; } | |
[[nodiscard]] bool use_default_implementation_for_nulls() const override { return false; } |
d6cdf78
to
4d2187c
Compare
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
|
||
String get_name() const override { return name; } | ||
bool is_variadic() const override { return false; } | ||
size_t get_number_of_arguments() const override { return 3; } |
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 'get_number_of_arguments' should be marked [[nodiscard]] [modernize-use-nodiscard]
size_t get_number_of_arguments() const override { return 3; } | |
[[nodiscard]] size_t get_number_of_arguments() const override { return 3; } |
run buildall |
TPC-H: Total hot run time: 49159 ms
|
TeamCity be ut coverage result: |
TPC-DS: Total hot run time: 211852 ms
|
ClickBench: Total hot run time: 30.34 s
|
Load test result on machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
|
7d390dc
to
6f16877
Compare
6f16877
to
7500e4b
Compare
run buildall |
TeamCity be ut coverage result: |
run external |
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. |
Proposed changes
pick #40948
Issue Number: close #xxx