In current Ethereum, smart contracts are executed by the CPU/RAM of nodes who are rewarded the gas from the transaction. Will this be the same in Casper? Are there any pools for this specific purpose currently?
1 Answer
This is not true, all full nodes process state, transactions, receipts, etc. This is in fact the reason why the Scalability Problem exists, Ethereum can only process O(c) load. Whenever a transaction is received in the mempool or contract code is executed, it is included in a block (given sufficient gasPrice and gasLimit, to be compliant with miners and fee schedules). PoS is simply a method of finalizing blocks in a probabilistic manner, dependent on validator stake. Blocks must be valid, and when they are valid, all full nodes execute the code in the EVM to verify that code has been executed correctly. In the case of zk-SNARKs, nodes process those to ensure that they are valid.
Nodes process all relevant code for a reason; redundant computation allows for decentralized consensus. So, to answer your first question, yes. All full nodes (that are working properly at least) will process contract code and transactions to produce new states, storage, and other data, even after Casper CBC is implemented.
Casper CBC (the final version by Zamfir) does not have pools for this purpose. Pools can exist, however. This would require a DAO-like construction to agree upon blocks for the DAO to attempt to stake. Voting can occur using either ETH or ERC-20 tokens. The DAO would also have a collective deposit of Ether, which is used to validate new blocks in Casper. This construction would delegate any earnings from PoS to the organization members, dependent on stake.
-
I am confused as to where rewards for code execution are distributed in this model. Would nodes receive that along with the reward for their stake? I was under the impression stake required a significant time period for deposit - what I am most curious about here is how code is being executed on the EVM specifically and who is being rewarded for that. Commented Jan 31, 2018 at 2:17