dataroaring commented on code in PR #10552:
URL: https://github.com/apache/doris/pull/10552#discussion_r912310257
##########
be/src/vec/sink/vtablet_sink.cpp:
##########
@@ -117,12 +117,17 @@ Status VOlapTableSink::send(RuntimeState* state,
vectorized::Block* input_block)
_partition_to_tablet_map.clear();
}
- //if pending bytes is more than 500M, wait
+ //if pending bytes is more than 500M, wait at most 1 min
constexpr size_t MAX_PENDING_BYTES = 500 * 1024 * 1024;
- if ( get_pending_bytes() > MAX_PENDING_BYTES){
- while(get_pending_bytes() < MAX_PENDING_BYTES){
- std::this_thread::sleep_for(std::chrono::microseconds(500));
- }
+ constexpr int max_retry = 120;
+ int retry = 0;
+ while (get_pending_bytes() > MAX_PENDING_BYTES && retry++ < max_retry) {
+ std::this_thread::sleep_for(std::chrono::microseconds(500));
+ }
+ if (get_pending_bytes() > MAX_PENDING_BYTES){
+ std::stringstream str;
+ str << "Load task " << _load_id << ": Memory exceed limit. ";
Review Comment:
Users may be confused by the error message. To me, it seems that I should
use a bigger exec_mem_limit, however, the actual failure is not due to memory
exceeds. Should we really fail the load task here ? If so, may be a message
"task stuck" should be reported?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]