Closed ChihChengLiang closed 3 years ago
We can likely implement this by adding a request hook that will 503 until the sync complete event is sent.
Per https://github.com/thehubbleproject/hubble-contracts/pull/606#discussion_r659975631 , we may need to group different routes by what mode the node is in and error (HTTP 4xx/5xx) if the route is currently unavailable. If we ever figure out a pattern where nodes can forward txns to the active proposer then all routes could be opened up.
What's wrong
The RPC client shouldn't be serving before the node is fully synced.
How can we fix it
Should return HTTP 503
TODO: Need to figure out how to implement this