cluster: Send SetLogPosition messages for all message types.

This commit is contained in:
Gunnar Beutner 2013-09-03 11:14:51 +02:00
parent 1b31ced475
commit 9c00e560ab
1 changed files with 5 additions and 5 deletions

View File

@ -676,11 +676,6 @@ void ClusterComponent::MessageHandler(const Endpoint::Ptr& sender, const Diction
{ {
RelayMessage(sender, message, true); RelayMessage(sender, message, true);
if (message->Get("method") == "cluster::HeartBeat") {
sender->SetSeen(Utility::GetTime());
return;
}
if (sender->GetRemoteLogPosition() + 10 < message->Get("ts")) { if (sender->GetRemoteLogPosition() + 10 < message->Get("ts")) {
Dictionary::Ptr lparams = boost::make_shared<Dictionary>(); Dictionary::Ptr lparams = boost::make_shared<Dictionary>();
lparams->Set("log_position", message->Get("ts")); lparams->Set("log_position", message->Get("ts"));
@ -695,6 +690,11 @@ void ClusterComponent::MessageHandler(const Endpoint::Ptr& sender, const Diction
sender->SetRemoteLogPosition(message->Get("ts")); sender->SetRemoteLogPosition(message->Get("ts"));
} }
if (message->Get("method") == "cluster::HeartBeat") {
sender->SetSeen(Utility::GetTime());
return;
}
Dictionary::Ptr params = message->Get("params"); Dictionary::Ptr params = message->Get("params");
if (!params) if (!params)