Skip to content

krakatoa: Support BroadcastTxSync #962

@technicallyty

Description

@technicallyty

DoD: Users can send txs via comet BroadcastTxSync API and get back a response with actual txn validation included WHILE using the comet app mempool and krakatoa evm mempool.

Current PR: Call CheckTx

Desired End State:

  • Remove abci lock from comet abci client checktx
  • Change app-side mempool to use sync behaviour, which returns only after it gets a lock and executes the rechecker on insert.
  • Needs a new local_client.go method (not ABCI) which calls checktx without a lock.
    • multi_app_cons -> mempool stuff locks on mempool stuff, consensus locks on consensus, etc.
    • probably needs slightly different

Ideas (not accepted):

  • option 1: call into mempool, acquire lock, execute tx rechecker, return response
    • On app side, call insert tx, return channel, wait in app before returning result to comet
    • On comet side, call insert tx, track tx being returned in reap tx, return success?
      • seems not great because failure logs would never get propagated back to the user
      • change ReapValidTxs response to include failed txs and the reasons they've been evicted from mempool.
  • option 2: move stateless check logic outside of mempool into app check tx, return stateless validation only
    • signature validation

Issue Repro:

  1. send tx with too low gas-prices
  2. attempt to query the returned hash
  3. tx not found

basically have no way of knowing now why my tx has failed to send.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions