1
0
mirror of https://github.com/codership/wsrep-lib.git synced 2025-07-21 12:22:06 +03:00

Fix for case where joiner shifts directly to synced state.

This commit is contained in:
Teemu Ollakka
2018-06-24 15:49:12 +03:00
parent d3821d88a5
commit 6a369a5d0e

View File

@ -287,15 +287,20 @@ void wsrep::server_state::on_sync()
{
wsrep::log_info() << "Server " << name_ << " synced with group";
wsrep::unique_lock<wsrep::mutex> lock(mutex_);
if (server_service_.sst_before_init())
{
switch (state_)
{
case s_connected:
state(lock, s_joiner);
// fall through
case s_joiner:
state(lock, s_initializing);
break;
case s_initialized:
state(lock, s_joined);
// fall through
default:
/* State */
state(lock, s_synced);