Question regarding scaling #436
-
This looks like a very interesting project. Personally i'm interested in scaling voting. |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments
-
Thanks for checking out hubble! 🤝 Here are some details that might help with your questions,
We run benchmarks with every PR via the CI, our latest merge shows 2600TPS which I think on par with other solutions. |
Beta Was this translation helpful? Give feedback.
-
ok well not the pubkeys, in your case its the list of txs, in order to create a dispute you need the TXs list to be submited with every state change, otherwise it is not possible to verify the state change (only in a case of dispute of course). also in the bls docs I saw somewhere is that it can scale nicely if the same message is signed by multiple signers but grows linearly with each message, so my question is, how is that scaling for txs? I assume each TX is a different message no? or the bls signatures is used for something else? |
Beta Was this translation helpful? Give feedback.
-
Hi @sirpy, Specifically, ECDSA needs 65 bytes for signature in the calldata, for each message. If we have n transactions, that would cost 65 * 16 * n gas in total. In contrast, BLS costs only 64 bytes in total for any number of messages. That said, you can see we have multiple signatures in the submitX functions. That's because we have a batch/commitment separation. A batch is the max number of transactions we can submit in an eth1 transaction, while a commitment is the max number of transactions we can dispute at once. To make the commitment disputable, we still need one signature per commitment. |
Beta Was this translation helpful? Give feedback.
-
@ChihChengLiang thanks for the quick response |
Beta Was this translation helpful? Give feedback.
-
@ChihChengLiang ok so now i see that the TXs are actually not stored on chain , and are just used to compute a merkle tree. |
Beta Was this translation helpful? Give feedback.
-
Tx data is available from the calldata, here's how to parse them https://github.com/thehubbleproject/hubble-commander/blob/b3ca690732414829f086b01e9d0334b47adbdac9/bazooka/calldata.go#L154
This is where burn auction comes in. An honest coordinator can outbid the malicious one to serve users. The auction result also reflects the cost of censorship, so people can know how expensive to censor/uncensor. |
Beta Was this translation helpful? Give feedback.
-
Transferring this to discussions |
Beta Was this translation helpful? Give feedback.
Hi @sirpy,
Yes, transactions are different messages to sign. The optimistic rollup improves the throughput by reducing the gas cost in the "submit batch" stage as much as possible. Using BLS signature, we can use fewer calldata than ECDSA.
Specifically, ECDSA needs 65 bytes for signature in the calldata, for each message. If we have n transactions, that would cost 65 * 16 * n gas in total. In contrast, BLS costs only 64 bytes in total for any number of messages.
That said, you can see we have multiple signatures in the submitX functions. That's because we have a batch/commitment separation. A batch is the max number of transactions we can submit in an eth1 transaction, while a commitment …