Pierre Chambart
47039ba9d1
Shell: fix merge problem in test
2018-06-19 12:15:27 +00:00
Pierre Chambart
8370b8fd69
Shell: Simplify early failure in case of locator incompatible with the checkpoint
2018-06-19 12:15:27 +00:00
Pierre Chambart
a7ef80fa34
Shell: Time error printing with more details
2018-06-19 12:15:27 +00:00
Pierre Chambart
2aeba212a7
Shell: Quick and dirty allowance of time shift
...
The right solution being to wait for the messages to be valid.
2018-06-19 12:15:27 +00:00
Grégoire Henry
fc0af4a55f
Shell: add option --checkpoint
to tezos-node run
2018-06-19 12:15:27 +00:00
Grégoire Henry
c16129a02d
Shell: early detection of branches that forks before the checkpoint.
2018-06-19 12:15:27 +00:00
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
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
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
Grégoire Henry
67566c271c
Shell: forced upgrades
2018-06-18 15:58:00 +02:00
Grégoire Henry
f615459200
Shell/RPC: /chains/<id>/mempool
new returned parsed operations
2018-06-14 22:57:04 +00:00
Grégoire Henry
c2517a0432
Shell: minor renaming
2018-06-14 22:57:04 +00:00
Vincent Bernardoff
a6bc6333da
Shell: use lmdb
for disk storage
2018-06-13 00:55:37 +02:00
Grégoire Henry
6f4a98f6fd
P2P: allow to limit the size of mempool
2018-06-12 21:27:55 +02:00
Grégoire Henry
fed04d4b8f
P2P: allow to limit the size of protocols
2018-06-12 21:27:55 +02:00
Grégoire Henry
99f6e40471
P2P: allow to limit the size of operations and operations list
2018-06-12 21:27:55 +02:00
Grégoire Henry
8072d413fc
P2P: allow to limit the size of block header
2018-06-12 21:27:55 +02:00
Grégoire Henry
85a25e200d
P2P: allow ti limit the length of list in requests
2018-06-12 21:27:55 +02:00
Grégoire Henry
a5cec8fca0
Proto: move back max_operation_data_length
as a constants
2018-06-12 21:27:55 +02:00
Grégoire Henry
22bf535d68
Shell: faster propagation of protocols
2018-06-11 09:24:41 +00:00
Grégoire Henry
5fd5c1c5f7
Dune: upgrade to 1.0+beta20
2018-06-08 15:27:23 +00:00
Grégoire Henry
ca1d4158a7
Shell/RPC: add raw block header in monitoring RPCs
2018-06-06 15:24:05 +02:00
Grégoire Henry
5aa65ee71f
Shell/RPC: allow to fetch raw Block_header
2018-06-06 15:24:05 +02:00
Benjamin Canou
23e1486564
RPC: add missing error registration
2018-06-06 10:54:33 +02:00
Grégoire Henry
030630ec0f
Data_encoding: mandatory title
to case
2018-06-06 10:54:33 +02:00
Grégoire Henry
632144b689
RPC: remove subfield accessors
...
This is painful to maintain and `jq` works well.
2018-06-06 10:54:33 +02:00
Grégoire Henry
420986b45b
Alpha: simplify the operation datatype
2018-06-06 10:54:33 +02:00
Grégoire Henry
33c3d1fcbd
Alpha/RPC: add a low-level but typed RPC for context introspection
...
Example:
```
> tezos-client rpc get /chains/main/blocks/head/context/raw/json/\?depth\=1 | jq
{
"commitments": [],
"contracts": {
"global_counter": 0,
"index": []
},
"cycle": [
4,
3,
2,
1,
0
],
"delegates": [
"tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN",
"tz1faswCTDciRzE4oJ9jn2Vm2dvjeyA9fUzU",
"tz1ddb9NMYHZi5UzPdzTZMYQQZoMub195zgv",
"tz1b7tUupMgCNw2cCLpKTkSD1NZzB5TkP2sv",
"tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx"
],
"last_block_priority": 0,
"rolls": {
"index": [],
"next": 2000,
"owner": {}
},
"votes": {
"ballots": [],
"current_period_kind": "proposal",
"current_quorum": 8000,
"listings": [],
"proposals": []
}
}
> tezos-client rpc get /chains/main/blocks/head/context/raw/json/cycle/4\?depth\=2 | jq
{
"last_roll": [
[
0,
2000
]
],
"nonces": [],
"random_seed": "97d50852c159ada8e9f107e98f693b059ba28336c723e6cd0f6353eb3c0cb415",
"roll_snapshot": 0
}
> tezos-client rpc get /chains/main/blocks/head/context/raw/json/cycle/5\?depth\=2 | jq
{
"last_roll": [
[
1,
2000
],
[
0,
2000
]
],
"nonces": [],
"roll_snapshot": 2
}
```
2018-06-06 10:54:33 +02:00
Grégoire Henry
f5e3fb17c0
Resto: lift the lwt monad into Resto.
2018-06-06 10:54:33 +02:00
Grégoire Henry
89cbe0f8fa
Docs/RPC: fix doc generation
...
The current doc generator does not handles path were multiple method
are registred. The fix remove the intermediate (compilation) tree.
2018-06-06 10:54:33 +02:00
Grégoire Henry
0a78bbe33b
Shell/RPC: use GET request for /workers
2018-06-06 10:54:33 +02:00
Grégoire Henry
64c464a73f
Shell/RPC: some module renaming/aliasing
2018-06-06 10:54:33 +02:00
Grégoire Henry
2a93a336aa
Shell/RPC: use query parameters in /injection
2018-06-06 10:54:33 +02:00
Grégoire Henry
9bc7b1e573
Shell/RPC: also list embedded protocols
2018-06-06 10:54:33 +02:00
Grégoire Henry
04c920df29
Shell/RPC: use query parameters in /protocols
2018-06-06 10:54:33 +02:00
Grégoire Henry
bbf5c7408b
Shell/RPC: split out Monitor_services
2018-06-06 10:54:33 +02:00
Grégoire Henry
0b08dce3e8
Shell/RPC: move preapply_operation
into Block_services
2018-06-06 10:54:33 +02:00
Grégoire Henry
d6f79edae2
Shell/RPC: rework /blocks
...
- start using `GET` and query parameters instead of `POST` when
meaningful
- inline parsed protocol data and metadata in block headers
- inline parsed protocol data and metadata in operations
- split the RPC in four categories:
- static data, available explicitly in block headers and operations
- static "metadata", information that were computed while validating
a block or an operation, but which are not explicit in the block
header (e.g. the baker of a block, the list of internal
transfer... (currently not implemented, but that's WIP))
- "context" all the static data we may read in the context
(contracts balance, list of delegates, ...)
- "helpers" are some RPC that may perform some computation.
2018-06-06 10:54:33 +02:00
Grégoire Henry
95a56753df
P2p: store connection_local_metadata
in P2p_connection.Info.t
2018-06-05 13:51:25 +02:00
Grégoire Henry
e610fcaade
P2p: read connection metadata before to accept connections
...
This will allow to decide whether to accept a connection or not
depending on its actual metadata.
2018-06-05 13:51:20 +02:00
OCamlPro-Iguernlala
4a16b3ef0b
P2p: add "private node" information in Connection_metadata.
...
Add private_node flag in Connection_metadata.t and update Node,
Distributed_db, P2p and P2p_pool to propagate the information
2018-06-05 13:40:00 +02:00
michael
aedf867e4a
RPC: Add conn_metadata to peer_info rpcs
2018-06-04 15:55:41 +02:00
michael
df4e474577
Shell: disable prevalidator if disable-mempool is used
2018-06-04 15:39:42 +02:00
michael
d5925f088c
P2p: Add option to disable the mempool
...
This allows a node to specify that it doesn't want to receive operations
that are not included in a block. To do so, one should use the new
--disable-mempool option.
A disabled mempool node announce its configuration during the ACK exchange.
This configuration should be easily expandable with other options.
Node will keep track of the ack exchange configuration for each nodes it
is connected to and will not propagate its mempool to disabled mempool
nodes.
A disabled mempool node will ignore non-empty mempool received.
In the future, this incident should be punish by a decrement of its score
and / or ban.
2018-06-04 15:35:22 +02:00
michael
a8e607a5a9
Shell: preliminary work for ack_cfg exchange
2018-06-01 16:25:43 +00:00