Conversation
|
No need for a separate request. We should gracefully skip if POST fails. |
|
POST can take too long to execute, because of either network issues or server being under load. |
|
Does this PR gracefully skip if POST fails?
For network issues, HEAD would take the same time. If the server is under load then i still don't see the point of the HEAD request? |
|
It skips even before the PR. let response = self.broadcast_client
.post(endpoint)
.body(tx_hex.to_string())
.send()
.await;and it returns the So, this PR is only adds timeouts. The reason to have HEAD and POST separately is to have different timeouts
|
Sends a HEAD request to the mempool transaction check server before attempting to check the actual transaction.
This prevents the client from getting stuck when the server is unavailable.