Skip to content

Commit b780dd5

Browse files
[enhancement](meta) Sync meta even if local state is not running
1 parent cccc9bb commit b780dd5

File tree

2 files changed

+0
-6
lines changed

2 files changed

+0
-6
lines changed

be/src/cloud/cloud_tablet.cpp

-3
Original file line numberDiff line numberDiff line change
@@ -867,9 +867,6 @@ Status CloudTablet::sync_meta() {
867867
}
868868
return st;
869869
}
870-
if (tablet_meta->tablet_state() != TABLET_RUNNING) { // impossible
871-
return Status::InternalError("invalid tablet state. tablet_id={}", tablet_id());
872-
}
873870

874871
auto new_ttl_seconds = tablet_meta->ttl_seconds();
875872
if (_tablet_meta->ttl_seconds() != new_ttl_seconds) {

be/src/cloud/cloud_tablet_mgr.cpp

-3
Original file line numberDiff line numberDiff line change
@@ -261,9 +261,6 @@ void CloudTabletMgr::sync_tablets(const CountDownLatch& stop_latch) {
261261

262262
for (auto& weak_tablet : weak_tablets) {
263263
if (auto tablet = weak_tablet.lock()) {
264-
if (tablet->tablet_state() != TABLET_RUNNING) {
265-
continue;
266-
}
267264
int64_t last_sync_time = tablet->last_sync_time_s;
268265
if (last_sync_time <= last_sync_time_bound) {
269266
sync_time_tablet_set.emplace(last_sync_time, weak_tablet);

0 commit comments

Comments
 (0)