IoTConsensus and IoTConsensusV2 no longer stores the peer list locally on the DataNode#14814
Merged
OneSizeFitsQuorum merged 8 commits intoapache:masterfrom Feb 17, 2025
Conversation
Pengzna
reviewed
Feb 13, 2025
| path.toString(), | ||
| new Peer(consensusGroupId, thisNodeId, thisNode), | ||
| new ArrayList<>(), | ||
| new TreeSet<>(), |
Collaborator
Author
There was a problem hiding this comment.
Previously, duplicates were removed during configuration persistence. Now that the persistence code is gone, a set is used to keep this logic.
TreeSet is used to return a List with a consistent order (for an interface), which I believe is better than the unordered HashSet.
...core/consensus/src/main/java/org/apache/iotdb/consensus/iot/logdispatcher/LogDispatcher.java
Outdated
Show resolved
Hide resolved
OneSizeFitsQuorum
approved these changes
Feb 14, 2025
This was referenced Feb 18, 2025
liyuheng55555
added a commit
to liyuheng55555/iotdb
that referenced
this pull request
Feb 19, 2025
…y on the DataNode (apache#14814) Co-authored-by: Peng Junzhi <201250214@smail.nju.edu.cn> Co-authored-by: Xiangpeng Hu <65238551+HxpSerein@users.noreply.github.com> (cherry picked from commit 4bd2f25)
OneSizeFitsQuorum
pushed a commit
that referenced
this pull request
Feb 21, 2025
…he DataNode (#14900) * IoTConsensus and IoTConsensusV2 no longer stores the peer list locally on the DataNode (#14814) Co-authored-by: Peng Junzhi <201250214@smail.nju.edu.cn> Co-authored-by: Xiangpeng Hu <65238551+HxpSerein@users.noreply.github.com> (cherry picked from commit 4bd2f25) * Fix IoTConsensus safe deleted index (#14883) * done * move (cherry picked from commit 9e973b7) * Fix IoTConsensus safe deleted index again (#14897) * ? * spotless (cherry picked from commit 4aadc09) * revert iotv2 * fix IT
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The new
resetPeerListinterface is super powerful.Now, IoTConsensus member management can be fully handled by ConfigNode, and DataNode can simply obtain the peer list from ConfigNode during startup (through
resetPeerListinterface).