diff options
author | Mission Liao <mission.liao@dexon.org> | 2018-12-13 09:55:14 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-13 09:55:14 +0800 |
commit | 06693fc13b451835ac460688903c7abb660710fb (patch) | |
tree | 22d1bfde3b023395cfe00c6df8a1edaebb0f7cce /simulation | |
parent | 338bf8676563a103cc78bbacef75fbaaac4293d7 (diff) | |
download | dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar.gz dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar.bz2 dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar.lz dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar.xz dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.tar.zst dexon-consensus-06693fc13b451835ac460688903c7abb660710fb.zip |
db: rename blockdb to db (#367)
* Rename blockdb package to db
* Rename 'BlockDB' to 'DB'
* Make all methods in db specific for ''block'.
* Rename db.BlockDatabase to db.Database
* Rename revealer to block-revealer
* Rename test.Revealer to test.BlockRevealer
Diffstat (limited to 'simulation')
-rw-r--r-- | simulation/node.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/simulation/node.go b/simulation/node.go index bacf86a..4d1e4ff 100644 --- a/simulation/node.go +++ b/simulation/node.go @@ -24,8 +24,8 @@ import ( "github.com/dexon-foundation/dexon-consensus/common" "github.com/dexon-foundation/dexon-consensus/core" - "github.com/dexon-foundation/dexon-consensus/core/blockdb" "github.com/dexon-foundation/dexon-consensus/core/crypto" + "github.com/dexon-foundation/dexon-consensus/core/db" "github.com/dexon-foundation/dexon-consensus/core/test" "github.com/dexon-foundation/dexon-consensus/core/types" "github.com/dexon-foundation/dexon-consensus/simulation/config" @@ -55,7 +55,7 @@ type message struct { // node represents a node in DexCon. type node struct { app core.Application - db blockdb.BlockDatabase + db db.Database gov *test.Governance netModule *test.Network ID types.NodeID @@ -81,7 +81,7 @@ func newNode( PeerPort: peerPort, }) id := types.NewNodeID(pubKey) - db, err := blockdb.NewMemBackedBlockDB(id.String() + ".blockdb") + dbInst, err := db.NewMemBackedDB(id.String() + ".db") if err != nil { panic(err) } @@ -118,7 +118,7 @@ func newNode( prvKey: prvKey, app: newSimApp(id, netModule, gov.State()), gov: gov, - db: db, + db: dbInst, netModule: netModule, } } |