`contain` function might not suitable to assert that "local node is in partitionTables"
- Lingua principale
- Java
- Stelle
- 6.4k
- Fork
- 1.2k
- Merge medio
- 1g 23h
- PR unite (30g)
- 115
Descrizione
**Describe the bug**
After updating 0.12.4 to 0.13.0, I make a mistake and run start-server rather than start-node.
Then I see an error: `All nodes in partitionTables must contain local node in start-server mode. `
Which appeared in line 416 https://github.com/apache/iotdb/blob/ac51b0802ac5d016f028fbfe829f8b8ab530740e/cluster/src/main/java/org/apache/iotdb/cluster/ClusterIoTDB.java#L411-L423
I checked the error log and find that the node has only one parameter which is different from nodes in `metaGroupMember`, `nodeIdentifier`.
In https://github.com/apache/iotdb/blob/ac51b0802ac5d016f028fbfe829f8b8ab530740e/cluster/src/main/java/org/apache/iotdb/cluster/utils/ClusterNode.java#L56-L62
I got `nodeIdentifier` is not parameter which should be the same. And I cannot find any place to change it, it's used for thrift. But is it necessary to keep the parameter `nodeIdentifier` the same?
If not, `contain` function might be rewritten。
**To Reproduce**
Am not really make sure this process will reproduce but am sure to get this error with the following procedure.
1. run start-cluster, then close it
2. run start-server, then close it
3. run start-cluster
4. See error
**Expected behavior**
This node should have been contained in all nodes, although nodeIdentifier is different.
**Desktop (please complete the following information):**
- OS: CentOS7
- Version 0.13.0
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Leggere il controllo di contenimento in cluster/src/main/java/org/apache/iotdb/cluster/ClusterIoTDB.java intorno alle righe 411-423 e i campi del nodo in cluster/src/main/java/org/apache/iotdb/cluster/utils/ClusterNode.java intorno alle righe 56-62. Riprodurre la sequenza segnalata di avvio e chiusura del cluster e del server, quindi determinare se valori nodeIdentifier diversi debbano comunque soddisfare il controllo di contenimento. Il lavoro è completato quando l'errore start-server segnalato non rifiuta più questo stato valido del nodo.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- java
- Ambito
- databases, distributed-systems
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 28/100