Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitbe9bd5b

Browse files
committed
Always try to send heartbeats.
Old behaviour here can cause subtle bugs, for exampleit can happened that none of mentioned conditiotions istrue when disabled node connects to a major node whichis online. So just send it allways.
1 parentcca50ae commitbe9bd5b

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

‎arbiter.c

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -359,11 +359,17 @@ static void MtmSendHeartbeat()
359359
for (i=0;i<Mtm->nAllNodes;i++)
360360
{
361361
if (i+1!=MtmNodeId) {
362-
if (!BIT_CHECK(busy_mask,i)
363-
&& (Mtm->status!=MTM_ONLINE
364-
||sockets[i] >=0
365-
|| !BIT_CHECK(Mtm->disabledNodeMask,i)
366-
||BIT_CHECK(Mtm->reconnectMask,i)))
362+
if (!BIT_CHECK(busy_mask,i))
363+
/*
364+
* Old behaviour here can cause subtle bugs, for example
365+
* it can happened that none of mentioned conditiotions is
366+
* true when disabled node connects to a major node which
367+
* is online. So just send it allways. --sk
368+
*/
369+
// && (Mtm->status != MTM_ONLINE
370+
// || sockets[i] >= 0
371+
// || !BIT_CHECK(Mtm->disabledNodeMask, i)
372+
// || BIT_CHECK(Mtm->reconnectMask, i)))
367373
{
368374
if (!MtmSendToNode(i,&msg,sizeof(msg))) {
369375
MTM_ELOG(LOG,"Arbiter failed to send heartbeat to node %d",i+1);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp