mirror of
https://github.com/arnaucube/hermez-node.git
synced 2026-02-07 03:16:45 +01:00
Add Last db view in kvdb and statedb
Last db view is an opened pebble db which always contains a checkpoint from the last batch. Methods to access this last batch are thread safe so that views of the last checkpoint can be made anywhere and with a consistent view of the state.
This commit is contained in:
@@ -355,6 +355,10 @@ func TestMain(m *testing.M) {
|
||||
panic(err)
|
||||
}
|
||||
}
|
||||
// Make a checkpoint to make the accounts available in Last
|
||||
if err := api.s.MakeCheckpoint(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
// Generate Coordinators and add them to HistoryDB
|
||||
const nCoords = 10
|
||||
|
||||
Reference in New Issue
Block a user