diff --git a/src/share/schema/ob_error_info.cpp b/src/share/schema/ob_error_info.cpp index e5bd327f01..5e66196a6b 100644 --- a/src/share/schema/ob_error_info.cpp +++ b/src/share/schema/ob_error_info.cpp @@ -462,7 +462,8 @@ int ObErrorInfo::handle_error_info(const IObErrorInfo *info, return ret; } -int ObErrorInfo::delete_error(const IObErrorInfo *info) +int ObErrorInfo::delete_error(const IObErrorInfo *info, + const ObObjectType obj_type) { int ret = OB_SUCCESS; ObMySQLProxy *sql_proxy = nullptr; @@ -471,7 +472,7 @@ int ObErrorInfo::delete_error(const IObErrorInfo *info) } else if (OB_ISNULL(sql_proxy = GCTX.sql_proxy_)) { ret = OB_ERR_UNEXPECTED; } else { - if (OB_FAIL(collect_error_info(info, NULL, true))) { + if (OB_FAIL(collect_error_info(info, NULL, true, obj_type))) { LOG_WARN("collect error info failed.", K(ret), K(info), K(*this)); } else { if (OB_FAIL(del_error(sql_proxy))) { diff --git a/src/share/schema/ob_error_info.h b/src/share/schema/ob_error_info.h index 7be054efb4..38e6b5bec8 100644 --- a/src/share/schema/ob_error_info.h +++ b/src/share/schema/ob_error_info.h @@ -118,7 +118,8 @@ public: int del_error(common::ObMySQLProxy *sql_proxy); int add_error(common::ObISQLClient & sql_client, bool is_replace, bool only_history); int get_error_obj_seq(common::ObISQLClient &sql_client, bool &exist); - int delete_error(const IObErrorInfo *info); + int delete_error(const IObErrorInfo *info, + const ObObjectType obj_type = ObObjectType::INVALID); TO_STRING_KV(K_(tenant_id), K_(obj_id),