patch 4.0

This commit is contained in:
wangzelin.wzl
2022-10-24 10:34:53 +08:00
parent 4ad6e00ec3
commit 93a1074b0c
10533 changed files with 2588271 additions and 2299373 deletions

View File

@ -13,68 +13,77 @@
#ifndef OCEANBASE_SRC_SQL_ENGINE_CMD_OB_INDEX_EXECUTOR_H_
#define OCEANBASE_SRC_SQL_ENGINE_CMD_OB_INDEX_EXECUTOR_H_
#include "lib/allocator/ob_allocator.h"
namespace oceanbase {
namespace obrpc {
namespace oceanbase
{
namespace obrpc
{
struct ObCreateIndexArg;
struct ObDropIndexArg;
struct ObAlterTableRes;
class ObCommonRpcProxy;
} // namespace obrpc
}
namespace sql {
namespace sql
{
class ObExecContext;
class ObCreateIndexStmt;
class ObSQLSessionInfo;
class ObCreateIndexExecutor {
class ObCreateIndexExecutor
{
public:
friend class ObAlterTableExecutor;
ObCreateIndexExecutor();
virtual ~ObCreateIndexExecutor();
int execute(ObExecContext& ctx, ObCreateIndexStmt& stmt);
int execute(ObExecContext &ctx, ObCreateIndexStmt &stmt);
private:
int set_drop_index_stmt_str(obrpc::ObDropIndexArg& drop_index_arg, common::ObIAllocator& allocator);
int sync_check_index_status(sql::ObSQLSessionInfo& my_session, obrpc::ObCommonRpcProxy& common_rpc_proxy,
const obrpc::ObCreateIndexArg& create_index_arg, common::ObIAllocator& allocator,
bool is_update_global_indexes = false);
int handle_session_exception(ObSQLSessionInfo& session);
int set_drop_index_stmt_str(
obrpc::ObDropIndexArg &drop_index_arg,
common::ObIAllocator &allocator);
int sync_check_index_status(sql::ObSQLSessionInfo &my_session,
obrpc::ObCommonRpcProxy &common_rpc_proxy,
const obrpc::ObCreateIndexArg &create_index_arg,
const obrpc::ObAlterTableRes &res,
common::ObIAllocator &allocator,
bool is_update_global_indexes = false);
int handle_session_exception(ObSQLSessionInfo &session);
int handle_switchover();
};
class ObDropIndexStmt;
class ObDropIndexExecutor {
class ObDropIndexExecutor
{
public:
ObDropIndexExecutor();
virtual ~ObDropIndexExecutor();
int execute(ObExecContext& ctx, ObDropIndexStmt& stmt);
int execute(ObExecContext &ctx, ObDropIndexStmt &stmt);
static int wait_drop_index_finish(
const uint64_t tenant_id,
const int64_t task_id,
sql::ObSQLSessionInfo &session);
};
class ObFlashBackIndexStmt;
class ObFlashBackIndexExecutor {
public:
ObFlashBackIndexExecutor()
{}
virtual ~ObFlashBackIndexExecutor()
{}
int execute(ObExecContext& ctx, ObFlashBackIndexStmt& stmt);
ObFlashBackIndexExecutor() {}
virtual ~ObFlashBackIndexExecutor() {}
int execute(ObExecContext &ctx, ObFlashBackIndexStmt &stmt);
private:
};
class ObPurgeIndexStmt;
class ObPurgeIndexExecutor {
public:
ObPurgeIndexExecutor()
{}
virtual ~ObPurgeIndexExecutor()
{}
int execute(ObExecContext& ctx, ObPurgeIndexStmt& stmt);
ObPurgeIndexExecutor() {}
virtual ~ObPurgeIndexExecutor() {}
int execute(ObExecContext &ctx, ObPurgeIndexStmt &stmt);
private:
};
} // namespace sql
} // namespace oceanbase
}
}
#endif /* OCEANBASE_SRC_SQL_ENGINE_CMD_OB_INDEX_EXECUTOR_H_ */