-
Notifications
You must be signed in to change notification settings - Fork 104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Eventlog contract calls time.Now() #2376
Comments
You can use cothority/byzcoin/statetrie.go Line 69 in 38ff4b7
An example is here: Line 312 in 6e09132
|
My understanding is that event logs could be accepted only between However, I have doubts concerning how BlockInterval is defined. However, on the following line, the magic number "4" is used as a multiplicative factor to create a window larger than BlockInterval to validate a block. What does that 4 represent? Is BlockInterval a hard timeout on the creation of a new block or is 4*BlockInterval ? Lines 2171 to 2178 in 63a2ff9
The BlockInterval parameter itself seems to be undocumented: Lines 167 to 170 in 63a2ff9
I'm happy to document it once this is clarified. |
Yes, documenting would be good ;) Historically, blockinterval was the time the leader spent between a new block has been generated, and the time it asked the other nodes if there are any new transactions pending. Which made two blocks appear about twice the Lately I changed the protocol to #2321, so that the nodes directly forward all transactions to the leader, who queues them up and creates blocks as long as there are transactions in the queue. So now the The magic |
@ineiti |
The basic assumption is that at least 2f+1 out of 3f+1 participants follow the protocol. So as long as only If the leader is byzantine (faulty or malicious), there will be a leader-rotation until a leader is found who successfully gets a block signed. So there is no heartbeat. If a node tries to get a transaction signed, and there is a timeout, he will propose to re-elect the leader. |
That is clear. I rather meant that, in my understanding, in the absence of activity (e.g. an instruction being sent by a client), no blocks are added. That is, there's no guarantee that no more than X [units of time] have passed since a block was last added to the ledger. Basically, if a cothority was active, but has been idle for the last month and everything is stable (all nodes continuously online, no failures, etc.), the latest block on the ledger will be from a month ago. Correct? It seems reasonable, I'm just trying to proceed with few assumptions as I am not yet familiar with the codebase. |
Yes, there are no 'filler' blocks that are sent with an empty list of transactions. Although the statistics at https://stats.c4dt.org produce about 10 blocks an hour. |
See also #2378 |
Bump @pierluca ? |
Contracts must be time invariant, but eventlog is not.
See also #1331.
The text was updated successfully, but these errors were encountered: