This is a dirty and non-optimized backend, it is still faster than the
current git backend.
Main drawbacks:
- the leveldb binding is non-coopertive, the node will
block while committing a block to the disk ;
- the leveldb use 'string' while internally we use 'cstruct',
this implies a lot of time-consuming 'memcpy'.
This is a rewrite of the build system with `jbuilder`, with just a
minimal toplevel Makefile for backward compatibility.
This first patch preserves the project architecture, we only gain
proper dependencies handling and always up-to-date `.merlin` files.
A latter patch may split the project in smaller "sub-package",
i.e. multiple `.opam` files.
The embedded versions of the economic protocol are now compiled with
`jbuilder` instead of `tezos-protocol-compiler`, potentially allowing
proper inlining at the cost of slightly-less-stricter
sandboxing. Nevertheless, dynamically loaded protocol are still
compiled with the `tezos-protocol-compiler` and thus strictly
sandboxed ; and a CI rule also checks the proper sandboxing of
embedded protocols.
This patch is coauthored with @hnrgrgr
- introduced `test/utils/test_lib.inc.sh` to simplify usage of
sandboxed node/client in the testsuite
- it reuses code from `./script/{node,client}_lib.inc.sh`
- use `wait_for_the_node_to_be_ready` to properly wait for the node to
be launched rather to use a fexed delay
- `test_multinode.sh` now launch 8 nodes.
Before this change, output from `alphanet.sh` looked like the following:
```
New contract alias 'my_account' saved.
Contract memorized as my_account.
\033[32mThe node is now running.\033[0m
\033[32mThe baker is now running.\033[0m
\033[32mThe endorser is now running.\033[0m
\033[33mWarning: the container contains a new version of 'alphanet.sh'.\033[0m
\033[33mYou might run './scripts/alphanet.sh update_script' to synchronize.\033[0m
```
I.e. control characters showed up, instead of modifying the color of the text
output. Repro'd on Container Linux (CoreOS) 1492.3.0.
After this change, `The node is now running` shows up in green &c.
Let's get serious. The full index of operations is not sustainable in
the production code. We now only keep the index of operations not yet
in the chain (i.e. the mempool/prevalidation). Operations from the
chain are now only accesible through a block. For instance, see the
RPC:
/blocks/<hash>/proto/operations