[master] fix mark session in retry for LargeQuery

This commit is contained in:
chinaxing
2023-02-07 17:33:25 +08:00
committed by ob-robot
parent b46b539702
commit 3d73ffb652
2 changed files with 5 additions and 1 deletions

View File

@ -178,6 +178,10 @@ public:
bool force_local_retry = false, bool force_local_retry = false,
bool is_inner_sql = false, bool is_inner_sql = false,
bool is_from_pl = false); bool is_from_pl = false);
void set_packet_retry(const int err) {
retry_type_ = RETRY_TYPE_PACKET;
retry_err_code_ = err;
}
void clear_state_before_each_retry(sql::ObQueryRetryInfo &retry_info) void clear_state_before_each_retry(sql::ObQueryRetryInfo &retry_info)
{ {
retry_type_ = RETRY_TYPE_NONE; retry_type_ = RETRY_TYPE_NONE;

View File

@ -793,7 +793,7 @@ OB_INLINE int ObMPQuery::do_process(ObSQLSessionInfo &session,
need_response_error = false; need_response_error = false;
} }
} else { } else {
session.set_session_in_retry(ObSessionRetryStatus::SESS_IN_RETRY); retry_ctrl_.set_packet_retry(ret);
session.get_retry_info_for_update().set_last_query_retry_err(ret); session.get_retry_info_for_update().set_last_query_retry_err(ret);
session.get_retry_info_for_update().inc_retry_cnt(); session.get_retry_info_for_update().inc_retry_cnt();
} }