OSDN Git Service

2d8bc135ed887814355509d8f227852e131d4d01
[bytom/bytom.git] / blockchain / txdb / internal / storage / storage.proto
1 syntax = "proto3";
2 option go_package = "storage";
3 package chain.core.txdb.internal.storage;
4
5 // Snapshot represents a snapshot of the blockchain, including the state
6 // tree and issuance memory.
7 message Snapshot {
8   // Nodes contains every node within the state tree, including interior nodes.
9   // The nodes are ordered according to a pre-order traversal.
10   repeated StateTreeNode nodes = 1;
11
12   // Nonces contains the record of recent nonces for ensuring
13   // uniqueness of issuances.
14   repeated Nonce nonces = 2;
15
16   message Nonce {
17     bytes  hash      = 1;
18     uint64 expiry_ms = 2;
19   }
20
21   message StateTreeNode {
22     bytes key = 1;
23   }
24 }
25
26 // Mainchain represents a mainchain of the blockchain
27 message Mainchain {
28
29   repeated Hash hashs = 1;
30
31   message Hash {
32     bytes key = 1;
33   }
34 }