lingbin commented on a change in pull request #2891: Some tiny refactor on
streaming-load related code
URL: https://github.com/apache/incubator-doris/pull/2891#discussion_r378278085
##########
File path: be/src/runtime/stream_load/stream_load_executor.cpp
##########
@@ -61,12 +61,10 @@ Status
StreamLoadExecutor::execute_plan_fragment(StreamLoadContext* ctx) {
ctx->number_filtered_rows =
executor->runtime_state()->num_rows_load_filtered();
ctx->number_unselected_rows =
executor->runtime_state()->num_rows_load_unselected();
- int64_t num_selected_rows =
- ctx->number_total_rows - ctx->number_unselected_rows;
- if ((0.0 + ctx->number_filtered_rows) / num_selected_rows >
ctx->max_filter_ratio) {
- status = Status::InternalError("too many filtered rows");
- }
- else if(ctx->number_loaded_rows == 0){
+ int64_t num_selected_rows = ctx->number_total_rows -
ctx->number_unselected_rows;
+ if ((double)ctx->number_filtered_rows / num_selected_rows >
ctx->max_filter_ratio) {
+ status = Status::InternalError("too many rows are filtered
out");
Review comment:
Ok
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]