You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/02/28 08:39:06 UTC
[GitHub] [iotdb] ericpai opened a new pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
ericpai opened a new pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131
See JIRA: https://issues.apache.org/jira/browse/IOTDB-2625
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] jamber001 commented on a change in pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
jamber001 commented on a change in pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131#discussion_r815836343
##########
File path: cluster/src/main/java/org/apache/iotdb/cluster/server/member/RaftMember.java
##########
@@ -260,6 +260,7 @@ public void start() {
}
startBackGroundThreads();
+ setSkipElection(false);
Review comment:
If because of this concern, what will happen when first time running this startBackGroundThreads() after IoTDB process starting up?
At that time, the skipElection is just false before running startBackGroundThreads().
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] ericpai merged pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
ericpai merged pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] jamber001 commented on a change in pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
jamber001 commented on a change in pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131#discussion_r815700985
##########
File path: cluster/src/main/java/org/apache/iotdb/cluster/server/member/RaftMember.java
##########
@@ -260,6 +260,7 @@ public void start() {
}
startBackGroundThreads();
+ setSkipElection(false);
Review comment:
setSkipElection(false); 放到 startBackGroundThreads(); 前面, 是不是 更好?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] ericpai commented on a change in pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
ericpai commented on a change in pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131#discussion_r815705565
##########
File path: cluster/src/main/java/org/apache/iotdb/cluster/server/member/RaftMember.java
##########
@@ -260,6 +260,7 @@ public void start() {
}
startBackGroundThreads();
+ setSkipElection(false);
Review comment:
If so, the status will be 'ready to launch election' before all the necessary threads starting (You can reference `RaftMember.startBackGroundThreads`). There are some corner cases that the heartbeat thread starts and launchs the election, but other threads, like `commitLog` and `appendLog` is not ready yet. Some unknown status and error may occur.
The safe way is to let `start()` be just a reverse-mirror of `stop()`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] ericpai commented on a change in pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
ericpai commented on a change in pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131#discussion_r816377856
##########
File path: cluster/src/main/java/org/apache/iotdb/cluster/server/member/RaftMember.java
##########
@@ -260,6 +260,7 @@ public void start() {
}
startBackGroundThreads();
+ setSkipElection(false);
Review comment:
You are right! The default value should be `true`, not `false`. I will optimize this in a new PR.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls commented on pull request #5131: [IOTDB-2625] Fix election deadlock when updating partition table
Posted by GitBox <gi...@apache.org>.
coveralls commented on pull request #5131:
URL: https://github.com/apache/iotdb/pull/5131#issuecomment-1054075241
[](https://coveralls.io/builds/46924149)
Coverage increased (+0.02%) to 67.724% when pulling **fd3d86810cfe897019d3e724ad281b46c71d3ed6 on ericpai:bugfix/iotdb-2625** into **92ad9f24b2d91490d532e0c829f19becad2c648f on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org