Commit Graph

2466 Commits

Author SHA1 Message Date
Grégoire Henry
6170ae2246 Shell: early detection of incompatible new heads and branches. 2018-06-19 12:15:27 +00:00
Grégoire Henry
96dd65e36d Shell: early detection of incompatible injected blocks 2018-06-19 12:15:27 +00:00
Grégoire Henry
a08d6b8cd9 Shell: update the checkpoint when updating the head
The new checkpoint is the current `last_allowed_fork_level` of the new
head.

When updating the checkpoint the shell tags as invalid all blocks with
a level strictly higher to the new checkpoint that are inconstant with
it. And it removes from the disk all the block with a level lower or
equal to the new checkpoint that do not belongs to the current
chain. Though, the shell removes nothing from the disk when the
current head is below the current checkpoint: this will allow to
configure an expected checkpoint when bootstraping a node.

The first patch is very conservative and only detects new incompatible
blocks when they are stored on disk (i.e. after the validation).
Fiture patches try to detect earlier such incompatible block.
2018-06-19 12:15:27 +00:00
Grégoire Henry
535616e21e Shell: add error for blocks inconsistent with the checkpoint 2018-06-19 12:15:27 +00:00
Grégoire Henry
d552c611c5 Shell: allow to store the current checkpoint of a chain
Currently initialized with the chain genesis.
2018-06-19 12:15:27 +00:00
Grégoire Henry
d02892b810 Shell: store the last allowed fork level 2018-06-19 12:15:27 +00:00
Grégoire Henry
a43ee47ee1 Shell: add a mli for validation errors 2018-06-19 12:15:27 +00:00
Grégoire Henry
b1d70d576c Shell: stricter fitness check on block injection 2018-06-19 12:15:27 +00:00
Grégoire Henry
ccad901f33 Shell: fix test network creation 2018-06-19 12:15:27 +00:00
Grégoire Henry
a0a2d6b004 Shell: filter out future block 2018-06-19 12:15:27 +00:00
Lý Kim Quyên
9d655696da Alpha: add missing balance updates in operation receipts 2018-06-19 06:12:44 +02:00
Grégoire Henry
3860d689d7 Opam: fix dependencies for tezos-signer-backends 2018-06-19 04:39:39 +02:00
Grégoire Henry
6792c61023 CI: fix scripts/gen_genesis.ml 2018-06-19 04:11:58 +02:00
Grégoire Henry
e1f66ffa85 Alphanet: add admin-client to alphanet.sh 2018-06-19 04:09:29 +02:00
Grégoire Henry
d832205e9c CI: fix build of the minimal docker image 2018-06-19 04:00:09 +02:00
Benjamin Canou
a838f5d55c Fix OPAM dependencies 2018-06-19 04:00:09 +02:00
Grégoire Henry
2fbd125511 Alpha: rename baker/endorser command: launch -> run 2018-06-19 03:16:42 +02:00
Grégoire Henry
ee2a126f3e Alpha: even simpler endorser 2018-06-19 03:11:17 +02:00
Benjamin Canou
c55a462233 Endorser: trust the node to choose the head 2018-06-19 03:06:21 +02:00
Vincent Botbol
9d021032e1 Docker: update docker configuration 2018-06-19 03:06:21 +02:00
Benjamin Canou
6682f05ec9 Baker: do not compare Lwt threads 2018-06-19 03:06:21 +02:00
Benjamin Canou
fdc6bf6b44 Baker, Endorser, exit on lost connection to node 2018-06-19 03:06:21 +02:00
Pierre Chambart
ce926e575a Teamwork: Prevent leaks with never_ending
Lwt_utils.never_ending is a global variable, hence a GC root. A promise
created by binding it cannot ever be garbage collected. This fixes the
known leak in the baker an endorser by allocating a fresh one for each
use (by turning it into a function). This porbably fix other slower
leaks.

High five Klakplok and Vincent.
2018-06-19 03:06:21 +02:00
Benjamin Canou
a09f2cc53e Alpha: drop old tests 2018-06-19 03:06:21 +02:00
Grégoire Henry
ec6db686d9 Alpha: remove block from endorsements 2018-06-19 03:06:21 +02:00
Galfour
392f6cec46 Tests: fix double_endorsement tests 2018-06-19 03:06:21 +02:00
Marco Stronati
b5c275c5fa Alpha: reintroduce duplicate endorsement error 2018-06-19 03:06:21 +02:00
Grégoire Henry
1ab9a7a72c Alpha: remove slots from endorsements 2018-06-19 03:06:21 +02:00
Benjamin Canou
41707f58d8 Baker: do not generate empty endorsements 2018-06-19 03:06:21 +02:00
Benjamin Canou
7500743a4d Baker: record max level at each block, not each nonce revelation 2018-06-19 03:06:21 +02:00
Benjamin Canou
93a72ca28d Baker: avoid infinite sleep to the past 2018-06-19 03:06:21 +02:00
Vincent Botbol
cf36510431 Docker: update docker configuration and fix wallet names 2018-06-19 03:06:21 +02:00
MBourgoin
4c65317681 Alpha/Baker: Use state_module to avoid double baking 2018-06-19 03:06:21 +02:00
MBourgoin
7d0c526644 Alpha/Endorser: Refactor State Module 2018-06-19 03:06:21 +02:00
Vincent Botbol
bea2344c3c Storage: clean up leveldb artifacts 2018-06-19 03:06:21 +02:00
Raphaël Proust
8b73e812ac Alpha/Baker: load protocol constants lazily
This avoids the baker refusing to start when the protocol alpha is not
yet activated.
2018-06-19 03:06:21 +02:00
Vincent Botbol
0fb25db95b Alpha/Baker: add quota checks and fee sorted manager operations inclusion + quick fix in simulator 2018-06-19 03:06:21 +02:00
Vincent Botbol
ea9b3ae68c Baker: add client-side validation 2018-06-19 03:06:21 +02:00
Vincent Botbol
0512ff55ce Baking: split daemons into 3 different binaries 2018-06-19 03:06:21 +02:00
Vincent Botbol
efee9df1c7 Baking: fix baking daemon error when run on genesis 2018-06-19 03:06:21 +02:00
Raphaël Proust
904103496d Alpha/Delegate: fix ci 2018-06-19 03:06:21 +02:00
Raphaël Proust
cb64c85d00 Alpha/Baker: keeping future slot for each delegate 2018-06-19 03:06:21 +02:00
MBourgoin
1d1bd2f7d1 Alpha/Endorser: less RPC calls 2018-06-19 03:06:21 +02:00
MBourgoin
669b1b02e7 Alpha/Endorser: Log timeout errors 2018-06-19 03:06:21 +02:00
MBourgoin
b9d97a7a94 Alpha/Endorser: typos 2018-06-19 03:06:21 +02:00
Raphaël Proust
ac20391c62 Alpha/daemons: some factorisation 2018-06-19 03:06:21 +02:00
Raphaël Proust
f221e21444 Alpha/Baker: keeping future slot for each delegate 2018-06-19 03:06:21 +02:00
Raphaël Proust
470a1e91f1 Alpha/Endorser: minor æsthetics 2018-06-19 03:06:21 +02:00
Raphaël Proust
a78eabda37 Alpha/Baker: Remember delegates 2018-06-19 03:06:21 +02:00
Raphaël Proust
3e71d21713 Alpha/Baker: better naming for error management 2018-06-19 03:06:21 +02:00