celestia-app icon indicating copy to clipboard operation
celestia-app copied to clipboard

ADR: Pay for multiple messages with a single `MsgPayForData`

Open evan-forbes opened this issue 3 years ago • 4 comments

Currently, each MsgPayForData transaction can only pay for a single message. Ideally, users would be able to pay for multiple messages using a single payment transaction. Not only that, but because this reduces the number of state transitions each full node would have to execute, we would want to incentivize this behavior, by adding some base fee to PayForData

evan-forbes avatar May 06 '22 14:05 evan-forbes

Are you proposing a consensus-critical change (i.e. having multiple data commitments per PFD), or an application-level standard?

adlerjohn avatar May 06 '22 19:05 adlerjohn

both?

fwiw @musalbas and @liamsi were discussing this idea earlier this week, and I just wanted to write it down so we can begin discussing it. It's not something I think would make mainnet imho

evan-forbes avatar May 06 '22 19:05 evan-forbes

More important than this would be to add an overhead cost to MsgPayForData, so that e.g. one MsgPayForData with 10KB of data is cheaper than two MsgPayForData with 5KB of data.

musalbas avatar May 08 '22 14:05 musalbas

Such an overhead doesn't necessarily have to be enforced by the protocol, but can rather be an emergent property of a separate fee market for Celestia-app transactions: https://github.com/celestiaorg/celestia-app/issues/738

adlerjohn avatar May 08 '22 15:05 adlerjohn

This becomes significantly easier after implementing #835

evan-forbes avatar Oct 30 '22 08:10 evan-forbes