mirror of
https://source.quilibrium.com/quilibrium/ceremonyclient.git
synced 2024-12-25 16:15:17 +00:00
v2.0.0-p3
This commit is contained in:
parent
aec21504bc
commit
3efeea0b06
@ -650,12 +650,10 @@ func FetchTokenBalance(client protobufs.NodeServiceClient) (TokenBalance, error)
|
|||||||
return TokenBalance{}, errors.Wrap(err, "error getting token info")
|
return TokenBalance{}, errors.Wrap(err, "error getting token info")
|
||||||
}
|
}
|
||||||
|
|
||||||
// owned := new(big.Int).SetBytes(info.OwnedTokens)
|
owned := new(big.Int).SetBytes(info.OwnedTokens)
|
||||||
unconfirmedOwned := new(big.Int).SetBytes(info.UnconfirmedOwnedTokens)
|
|
||||||
|
|
||||||
return TokenBalance{
|
return TokenBalance{
|
||||||
// Owned: owned,
|
Owned: owned,
|
||||||
UnconfirmedOwned: unconfirmedOwned,
|
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -20,6 +20,7 @@ type Node struct {
|
|||||||
logger *zap.Logger
|
logger *zap.Logger
|
||||||
dataProofStore store.DataProofStore
|
dataProofStore store.DataProofStore
|
||||||
clockStore store.ClockStore
|
clockStore store.ClockStore
|
||||||
|
coinStore store.CoinStore
|
||||||
keyManager keys.KeyManager
|
keyManager keys.KeyManager
|
||||||
pubSub p2p.PubSub
|
pubSub p2p.PubSub
|
||||||
execEngines map[string]execution.ExecutionEngine
|
execEngines map[string]execution.ExecutionEngine
|
||||||
@ -44,6 +45,7 @@ func newNode(
|
|||||||
logger *zap.Logger,
|
logger *zap.Logger,
|
||||||
dataProofStore store.DataProofStore,
|
dataProofStore store.DataProofStore,
|
||||||
clockStore store.ClockStore,
|
clockStore store.ClockStore,
|
||||||
|
coinStore store.CoinStore,
|
||||||
keyManager keys.KeyManager,
|
keyManager keys.KeyManager,
|
||||||
pubSub p2p.PubSub,
|
pubSub p2p.PubSub,
|
||||||
// execution engines wire in here
|
// execution engines wire in here
|
||||||
@ -59,6 +61,7 @@ func newNode(
|
|||||||
logger,
|
logger,
|
||||||
dataProofStore,
|
dataProofStore,
|
||||||
clockStore,
|
clockStore,
|
||||||
|
coinStore,
|
||||||
keyManager,
|
keyManager,
|
||||||
pubSub,
|
pubSub,
|
||||||
execEngines,
|
execEngines,
|
||||||
@ -172,6 +175,10 @@ func (n *Node) GetClockStore() store.ClockStore {
|
|||||||
return n.clockStore
|
return n.clockStore
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (n *Node) GetCoinStore() store.CoinStore {
|
||||||
|
return n.coinStore
|
||||||
|
}
|
||||||
|
|
||||||
func (n *Node) GetDataProofStore() store.DataProofStore {
|
func (n *Node) GetDataProofStore() store.DataProofStore {
|
||||||
return n.dataProofStore
|
return n.dataProofStore
|
||||||
}
|
}
|
||||||
|
@ -40,6 +40,7 @@ func NewDebugNode(configConfig *config.Config, selfTestReport *protobufs.SelfTes
|
|||||||
pebbleDB := store.NewPebbleDB(dbConfig)
|
pebbleDB := store.NewPebbleDB(dbConfig)
|
||||||
pebbleDataProofStore := store.NewPebbleDataProofStore(pebbleDB, zapLogger)
|
pebbleDataProofStore := store.NewPebbleDataProofStore(pebbleDB, zapLogger)
|
||||||
pebbleClockStore := store.NewPebbleClockStore(pebbleDB, zapLogger)
|
pebbleClockStore := store.NewPebbleClockStore(pebbleDB, zapLogger)
|
||||||
|
pebbleCoinStore := store.NewPebbleCoinStore(pebbleDB, zapLogger)
|
||||||
keyConfig := configConfig.Key
|
keyConfig := configConfig.Key
|
||||||
fileKeyManager := keys.NewFileKeyManager(keyConfig, zapLogger)
|
fileKeyManager := keys.NewFileKeyManager(keyConfig, zapLogger)
|
||||||
p2PConfig := configConfig.P2P
|
p2PConfig := configConfig.P2P
|
||||||
@ -50,7 +51,7 @@ func NewDebugNode(configConfig *config.Config, selfTestReport *protobufs.SelfTes
|
|||||||
masterTimeReel := time.NewMasterTimeReel(zapLogger, pebbleClockStore, engineConfig, wesolowskiFrameProver)
|
masterTimeReel := time.NewMasterTimeReel(zapLogger, pebbleClockStore, engineConfig, wesolowskiFrameProver)
|
||||||
inMemoryPeerInfoManager := p2p.NewInMemoryPeerInfoManager(zapLogger)
|
inMemoryPeerInfoManager := p2p.NewInMemoryPeerInfoManager(zapLogger)
|
||||||
masterClockConsensusEngine := master.NewMasterClockConsensusEngine(engineConfig, zapLogger, pebbleClockStore, fileKeyManager, blossomSub, kzgInclusionProver, wesolowskiFrameProver, masterTimeReel, inMemoryPeerInfoManager, selfTestReport)
|
masterClockConsensusEngine := master.NewMasterClockConsensusEngine(engineConfig, zapLogger, pebbleClockStore, fileKeyManager, blossomSub, kzgInclusionProver, wesolowskiFrameProver, masterTimeReel, inMemoryPeerInfoManager, selfTestReport)
|
||||||
node, err := newNode(zapLogger, pebbleDataProofStore, pebbleClockStore, fileKeyManager, blossomSub, masterClockConsensusEngine)
|
node, err := newNode(zapLogger, pebbleDataProofStore, pebbleClockStore, pebbleCoinStore, fileKeyManager, blossomSub, masterClockConsensusEngine)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -63,6 +64,7 @@ func NewNode(configConfig *config.Config, selfTestReport *protobufs.SelfTestRepo
|
|||||||
pebbleDB := store.NewPebbleDB(dbConfig)
|
pebbleDB := store.NewPebbleDB(dbConfig)
|
||||||
pebbleDataProofStore := store.NewPebbleDataProofStore(pebbleDB, zapLogger)
|
pebbleDataProofStore := store.NewPebbleDataProofStore(pebbleDB, zapLogger)
|
||||||
pebbleClockStore := store.NewPebbleClockStore(pebbleDB, zapLogger)
|
pebbleClockStore := store.NewPebbleClockStore(pebbleDB, zapLogger)
|
||||||
|
pebbleCoinStore := store.NewPebbleCoinStore(pebbleDB, zapLogger)
|
||||||
keyConfig := configConfig.Key
|
keyConfig := configConfig.Key
|
||||||
fileKeyManager := keys.NewFileKeyManager(keyConfig, zapLogger)
|
fileKeyManager := keys.NewFileKeyManager(keyConfig, zapLogger)
|
||||||
p2PConfig := configConfig.P2P
|
p2PConfig := configConfig.P2P
|
||||||
@ -73,7 +75,7 @@ func NewNode(configConfig *config.Config, selfTestReport *protobufs.SelfTestRepo
|
|||||||
masterTimeReel := time.NewMasterTimeReel(zapLogger, pebbleClockStore, engineConfig, wesolowskiFrameProver)
|
masterTimeReel := time.NewMasterTimeReel(zapLogger, pebbleClockStore, engineConfig, wesolowskiFrameProver)
|
||||||
inMemoryPeerInfoManager := p2p.NewInMemoryPeerInfoManager(zapLogger)
|
inMemoryPeerInfoManager := p2p.NewInMemoryPeerInfoManager(zapLogger)
|
||||||
masterClockConsensusEngine := master.NewMasterClockConsensusEngine(engineConfig, zapLogger, pebbleClockStore, fileKeyManager, blossomSub, kzgInclusionProver, wesolowskiFrameProver, masterTimeReel, inMemoryPeerInfoManager, selfTestReport)
|
masterClockConsensusEngine := master.NewMasterClockConsensusEngine(engineConfig, zapLogger, pebbleClockStore, fileKeyManager, blossomSub, kzgInclusionProver, wesolowskiFrameProver, masterTimeReel, inMemoryPeerInfoManager, selfTestReport)
|
||||||
node, err := newNode(zapLogger, pebbleDataProofStore, pebbleClockStore, fileKeyManager, blossomSub, masterClockConsensusEngine)
|
node, err := newNode(zapLogger, pebbleDataProofStore, pebbleClockStore, pebbleCoinStore, fileKeyManager, blossomSub, masterClockConsensusEngine)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -36,5 +36,5 @@ func FormatVersion(version []byte) string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func GetPatchNumber() byte {
|
func GetPatchNumber() byte {
|
||||||
return 0x02
|
return 0x03
|
||||||
}
|
}
|
||||||
|
@ -424,6 +424,7 @@ func main() {
|
|||||||
node.GetLogger(),
|
node.GetLogger(),
|
||||||
node.GetDataProofStore(),
|
node.GetDataProofStore(),
|
||||||
node.GetClockStore(),
|
node.GetClockStore(),
|
||||||
|
node.GetCoinStore(),
|
||||||
node.GetKeyManager(),
|
node.GetKeyManager(),
|
||||||
node.GetPubSub(),
|
node.GetPubSub(),
|
||||||
node.GetMasterClock(),
|
node.GetMasterClock(),
|
||||||
|
@ -336,6 +336,7 @@ func NewRPCServer(
|
|||||||
logger *zap.Logger,
|
logger *zap.Logger,
|
||||||
dataProofStore store.DataProofStore,
|
dataProofStore store.DataProofStore,
|
||||||
clockStore store.ClockStore,
|
clockStore store.ClockStore,
|
||||||
|
coinStore store.CoinStore,
|
||||||
keyManager keys.KeyManager,
|
keyManager keys.KeyManager,
|
||||||
pubSub p2p.PubSub,
|
pubSub p2p.PubSub,
|
||||||
masterClock *master.MasterClockConsensusEngine,
|
masterClock *master.MasterClockConsensusEngine,
|
||||||
@ -347,6 +348,7 @@ func NewRPCServer(
|
|||||||
logger: logger,
|
logger: logger,
|
||||||
dataProofStore: dataProofStore,
|
dataProofStore: dataProofStore,
|
||||||
clockStore: clockStore,
|
clockStore: clockStore,
|
||||||
|
coinStore: coinStore,
|
||||||
keyManager: keyManager,
|
keyManager: keyManager,
|
||||||
pubSub: pubSub,
|
pubSub: pubSub,
|
||||||
masterClock: masterClock,
|
masterClock: masterClock,
|
||||||
|
Loading…
Reference in New Issue
Block a user