Consider increasing `TimeoutBroadcastTxCommit`
Opened this issue · 2 comments
Context
celestia-core/config/config.go
Line 439 in 5cfce0b
Problem
Feedback from @joroshiba
Digging into code I've noticed that blob submission through celestia-node via code pulled from celestia-app utilizes a syncronous broadcast tx call which defaults to timing out after 10s (https://github.com/celestiaorg/celestia-core/blob/main/config/config.go#L439), although configurable by each node. The average blocktime on Celestia is about 11s. This seems to means that if you submit a TX via celestia node or celestia app near the beggining of a block timing you will most likely get a timeout error?
Proposal
- Confirm that this timeout gets hit if a user tries to submit a transaction when > 10 seconds remain until the next block is produced. In other words, attempt to broadcast a transaction immediately after a block is produced.
- Consider bumping the timeout to something larger than mainnet block time (~12 seconds) so ~15 seconds.
- Confirm that this timeout doesn't get hit anymore
The 10 second timeout looks already overwritten in celestia-app here. Related: celestiaorg/celestia-app#1034
In a node I have locally, the ~/.celestia-app/config/config.toml
contains:
# How long to wait for a tx to be committed during /broadcast_tx_commit.
# WARNING: Using a value larger than 10s will result in increasing the
# global HTTP write timeout, which applies to all connections and endpoints.
# See https://github.com/tendermint/tendermint/issues/3435
timeout_broadcast_tx_commit = "50s"
which makes me think the 10 second timeout alluded to in the OP is not actually the timeout getting hit. There are other timeouts in the config files. For example ~/.celestia-app/config/app.toml
:
# RPCReadTimeout defines the Tendermint RPC read timeout (in seconds).
rpc-read-timeout = 10
@joroshiba do you know which consensus full node you're connected to? It would be nice if we can verify what value they use for timeout_broadcast_tx_commit
.