-
Notifications
You must be signed in to change notification settings - Fork 92
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
factomd chain-head
returns chaininprocesslist
==true on block N+1, where N – block, in which chain included
#678
Comments
Test 2 with addition of new entry into existing chain. Step 1 (block N):
Step 2 (block N+1):
Step 3 (block N+2):
So, the issue exists in this case too and it is not linked with creating new chain. |
Relevant code (i think) for anyone that doesn't want to go digging for it: Lines 935 to 942 in d2e5799
My possible interpretation is that it checks a range of 2 blocks to cover up an error that happens if the state moves on to the next height (ie the chain is not in the processlist) but the block hasn't been saved to the database yet (ie the chain is missing from the database) in the section just below my highlight? |
I also thought maybe it was designed initially to work like this? Need to ask @carryforward |
Thank you for reporting this @ilzheev. This is related to one of the quirks of the factomd system. There is a limbo period between minute 0 and minute 1 when following along with blocks. It is kind of an uncertainty period, similar to single confirmations in bitcoin. Only after minute 1 passes does your factomd node know that the federated servers saw each other's DBsigs. When designing the API, this level of uncertainty was not well understood and is not well articulated through the return data. There is an unused status where you would know if your item has been put in the process list and an EOM has been processed after your item, which would indicate that all the federated servers saw that your item had been acknowledged. That is less important that actually being saved to the database though. A better solution would be between minute 0 and 1, when there isn't an entry scheduled to go into the requested chain FD-916 was made to track this ticket. I'm not sure how hard this is going to be. We will likely need a better way of of presenting uncertainty through the chain-head API in the future. |
Step 1:
Chain & few entries in it created on block N.
chain-head
call at 0-10 min on block N returns:Step 2:
Then, chain & all entries included in block N.
No new entries submitted on block N+1.
chain-head
call at 0-10 min on block N+1 returns:Step 3:
chain-head
call at 0-10 min on block N+2 returns:The text was updated successfully, but these errors were encountered: