Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
大炮V587
oceanbase
提交
819ca6fe
O
oceanbase
项目概览
大炮V587
/
oceanbase
与 Fork 源项目一致
Fork自
oceanbase / oceanbase
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
oceanbase
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
819ca6fe
编写于
3月 17, 2023
作者:
O
obdev
提交者:
ob-robot
3月 17, 2023
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix unexpected index build task result when retry to checkum unique index checksum.
上级
ba694984
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
7 addition
and
12 deletion
+7
-12
src/rootserver/ddl_task/ob_ddl_task.cpp
src/rootserver/ddl_task/ob_ddl_task.cpp
+6
-10
src/rootserver/ddl_task/ob_ddl_task.h
src/rootserver/ddl_task/ob_ddl_task.h
+1
-2
未找到文件。
src/rootserver/ddl_task/ob_ddl_task.cpp
浏览文件 @
819ca6fe
...
...
@@ -2032,7 +2032,6 @@ int ObDDLWaitColumnChecksumCtx::init(
void
ObDDLWaitColumnChecksumCtx
::
reset
()
{
is_inited_
=
false
;
is_calc_done_
=
false
;
source_table_id_
=
OB_INVALID_ID
;
target_table_id_
=
OB_INVALID_ID
;
schema_version_
=
0
;
...
...
@@ -2051,12 +2050,11 @@ int ObDDLWaitColumnChecksumCtx::try_wait(bool &is_column_checksum_ready)
int64_t
success_count
=
0
;
int64_t
send_succ_count
=
0
;
int
ret
=
OB_SUCCESS
;
bool
is_calc_done
=
false
;
if
(
OB_UNLIKELY
(
!
is_inited_
))
{
ret
=
OB_NOT_INIT
;
LOG_WARN
(
"not init"
,
K
(
ret
),
K
(
is_inited_
));
}
else
if
(
is_calc_done_
)
{
// do nothing
}
else
{
}
else
if
(
!
is_calc_done
)
{
SpinRLockGuard
guard
(
lock_
);
const
int64_t
check_count
=
stat_array_
.
count
();
for
(
int64_t
i
=
0
;
OB_SUCC
(
ret
)
&&
i
<
check_count
;
++
i
)
{
...
...
@@ -2067,7 +2065,7 @@ int ObDDLWaitColumnChecksumCtx::try_wait(bool &is_column_checksum_ready)
}
else
if
(
item
.
snapshot_
<=
0
)
{
// calc rpc not send, by pass
}
else
if
(
CCS_FAILED
==
item
.
col_checksum_stat_
)
{
is_calc_done
_
=
true
;
is_calc_done
=
true
;
ret
=
item
.
ret_code_
;
LOG_WARN
(
"current column checksum status failed"
,
K
(
ret
),
K
(
item
));
}
else
if
(
item
.
col_checksum_stat_
==
ColChecksumStat
::
CCS_SUCCEED
)
{
...
...
@@ -2075,10 +2073,11 @@ int ObDDLWaitColumnChecksumCtx::try_wait(bool &is_column_checksum_ready)
}
}
if
(
check_count
==
success_count
)
{
is_calc_done_
=
true
;
is_calc_done
=
true
;
is_column_checksum_ready
=
true
;
}
}
if
(
OB_SUCC
(
ret
)
&&
!
is_calc_done
_
)
{
if
(
OB_SUCC
(
ret
)
&&
!
is_calc_done
)
{
if
(
0
!=
last_drive_ts_
&&
last_drive_ts_
+
timeout_us_
<
ObTimeUtility
::
current_time
())
{
// wait too long, refresh to retry send rpc
if
(
OB_FAIL
(
refresh_zombie_task
()))
{
...
...
@@ -2092,7 +2091,6 @@ int ObDDLWaitColumnChecksumCtx::try_wait(bool &is_column_checksum_ready)
last_drive_ts_
=
ObTimeUtility
::
current_time
();
}
}
is_column_checksum_ready
=
is_calc_done_
;
if
(
REACH_TIME_INTERVAL
(
1000L
*
1000L
))
{
LOG_INFO
(
"try wait checksum"
,
K
(
ret
),
K
(
stat_array_
.
count
()),
K
(
success_count
),
K
(
send_succ_count
));
}
...
...
@@ -2217,8 +2215,6 @@ int ObDDLWaitColumnChecksumCtx::send_calc_rpc(int64_t &send_succ_count)
if
(
OB_UNLIKELY
(
!
is_inited_
))
{
ret
=
OB_NOT_INIT
;
LOG_WARN
(
"not init"
,
K
(
ret
),
K
(
is_inited_
));
}
else
if
(
is_calc_done_
)
{
// do nothing
}
else
if
(
OB_ISNULL
(
root_service
=
GCTX
.
root_service_
)
||
OB_ISNULL
(
location_service
=
GCTX
.
location_service_
))
{
ret
=
OB_ERR_SYS
;
...
...
src/rootserver/ddl_task/ob_ddl_task.h
浏览文件 @
819ca6fe
...
...
@@ -593,7 +593,7 @@ public:
bool
is_inited
()
const
{
return
is_inited_
;
}
int
try_wait
(
bool
&
is_column_checksum_ready
);
int
update_status
(
const
common
::
ObTabletID
&
tablet_id
,
const
int
ret_code
);
TO_STRING_KV
(
K
(
is_inited_
),
K
(
is_calc_done_
),
K
(
source_table_id_
),
K
(
target_table_id_
),
TO_STRING_KV
(
K
(
is_inited_
),
K
(
source_table_id_
),
K
(
target_table_id_
),
K
(
schema_version_
),
K
(
snapshot_version_
),
K
(
execution_id_
),
K
(
timeout_us_
),
K
(
last_drive_ts_
),
K
(
stat_array_
),
K_
(
tenant_id
));
...
...
@@ -603,7 +603,6 @@ private:
private:
bool
is_inited_
;
bool
is_calc_done_
;
uint64_t
source_table_id_
;
uint64_t
target_table_id_
;
int64_t
schema_version_
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录