@@ -2323,8 +2323,9 @@ void MetaServiceImpl::get_delete_bitmap_update_lock(google::protobuf::RpcControl
2323
2323
lock_key_not_found = true ;
2324
2324
std::string current_lock_msg = " lock key not found" ;
2325
2325
lock_info.set_lock_id (request->lock_id ());
2326
+ // compaction does not use this expiration, only used when upgrade ms
2327
+ lock_info.set_expiration (expiration);
2326
2328
if (request->lock_id () != COMPACTION_DELETE_BITMAP_LOCK_ID) {
2327
- lock_info.set_expiration (expiration);
2328
2329
lock_info.add_initiators (request->initiator ());
2329
2330
} else {
2330
2331
// in normal case, this should remove 0 kvs
@@ -2361,7 +2362,6 @@ void MetaServiceImpl::get_delete_bitmap_update_lock(google::protobuf::RpcControl
2361
2362
<< " expiration=" << lock_info.expiration () << " now=" << now
2362
2363
<< " initiator_size=" << lock_info.initiators_size ();
2363
2364
lock_info.clear_initiators ();
2364
- lock_info.clear_expiration ();
2365
2365
} else if (lock_info.lock_id () != request->lock_id ()) {
2366
2366
ss << " already be locked by lock_id=" << lock_info.lock_id ()
2367
2367
<< " expiration=" << lock_info.expiration () << " now=" << now
@@ -2374,8 +2374,9 @@ void MetaServiceImpl::get_delete_bitmap_update_lock(google::protobuf::RpcControl
2374
2374
std::string current_lock_msg =
2375
2375
" original lock_id=" + std::to_string (lock_info.lock_id ());
2376
2376
lock_info.set_lock_id (request->lock_id ());
2377
+ // compaction does not use the expiration, only used when upgrade ms
2378
+ lock_info.set_expiration (expiration);
2377
2379
if (request->lock_id () != COMPACTION_DELETE_BITMAP_LOCK_ID) {
2378
- lock_info.set_expiration (expiration);
2379
2380
bool found = false ;
2380
2381
for (auto initiator : lock_info.initiators ()) {
2381
2382
if (request->initiator () == initiator) {
0 commit comments