@@ -2095,8 +2095,10 @@ void server_state::drop_partition(std::shared_ptr<app_state> &app, int pidx)
2095
2095
request.type = config_type::CT_DROP_PARTITION;
2096
2096
SET_OBJ_IP_AND_HOST_PORT (request, node, pc, primary);
2097
2097
2098
- maintain_drops (request, pc, true );
2099
- maintain_drops (request, pc, false );
2098
+ MAINTAIN_DROP_NODES (request.config , hp_secondaries, hp_last_drops, request.type );
2099
+ MAINTAIN_DROP_NODES (request.config , secondaries, last_drops, request.type );
2100
+ MAINTAIN_DROP_NODE (request.config , hp_primary, hp_last_drops, request.type );
2101
+ MAINTAIN_DROP_NODE (request.config , primary, last_drops, request.type );
2100
2102
2101
2103
RESET_IP_AND_HOST_PORT (request.config , primary);
2102
2104
CLEAR_IP_AND_HOST_PORT (request.config , secondaries);
@@ -2158,7 +2160,9 @@ void server_state::downgrade_primary_to_inactive(std::shared_ptr<app_state> &app
2158
2160
SET_OBJ_IP_AND_HOST_PORT (request, node, pc, primary);
2159
2161
request.config .ballot ++;
2160
2162
RESET_IP_AND_HOST_PORT (request.config , primary);
2161
- maintain_drops (request, pc, false );
2163
+ MAINTAIN_DROP_NODE (request.config , hp_primary, hp_last_drops, request.type );
2164
+ MAINTAIN_DROP_NODE (request.config , primary, last_drops, request.type );
2165
+ // maintain_drops(request, pc, false);
2162
2166
2163
2167
cc.stage = config_status::pending_remote_sync;
2164
2168
cc.pending_sync_request = req;
@@ -2295,12 +2299,8 @@ void server_state::on_update_configuration(
2295
2299
msg->release_ref ();
2296
2300
return ;
2297
2301
} else {
2298
- partition_configuration pc;
2299
- pc.hp_primary = cfg_request->hp_node ;
2300
- pc.primary = cfg_request->node ;
2301
- pc.hp_secondaries = cfg_request->config .hp_secondaries ;
2302
- pc.secondaries = cfg_request->config .secondaries ;
2303
- maintain_drops (*cfg_request, pc, false );
2302
+ MAINTAIN_DROP_NODES (cfg_request->config , hp_node, hp_last_drops, cfg_request->type );
2303
+ MAINTAIN_DROP_NODES (cfg_request->config , node, last_drops, cfg_request->type );
2304
2304
}
2305
2305
2306
2306
if (response.err != ERR_IO_PENDING) {
0 commit comments