I am running two nodes on two different machines and geth installed, and for educational purposes I would like to make both nodes work concurrently. I know that nonce management is quite pain in the *** by default on only one machine, but I am very keen into implementing this with concurrency. Challenge on max level.
Problem I am trying to resolve is how to keep nonces synchronized between different nodes for an address 0x123 for example.
So I have to follow nonce per address. Giving that we are using address 0x123 for this example.
State: Largest nonce from both nodes is 4. Updates db with 4.
State: Account Nonce 4, Node A Pending transaction nonce 5, Node B Pending transaction nonce is lower than Node A
State: Account Nonce 4, Node A Pending transaction nonce 5, Node B Pending transaction nonce 5
So pretty much idea is to keep a track for nonce between different nodes. Is this viable option, or is there better and more robust way to do this?