xaya / libxayagame

MIT License
21 stars 19 forks source link

Probe and fix GSP connection to Xaya Core #121

Closed domob1812 closed 2 years ago

domob1812 commented 2 years ago

This set of changes tries to make the connection a GSP has to Xaya Core (or Xaya X) more robust. If an exception is thrown while processing a block (for instance) - e.g. because Xaya Core's JSON-RPC interface has issues -, then the state is temporarily changed to disconnected. The same happens if no ZMQ updates for blocks are received for a long time. Later on, the GSP attempts to reconnect to Xaya Core and re-establish the ZMQ connection, so it can carry on when Xaya Core works again.

The new functionality comes with two command-line flags to toggle and configure it: