Skip to content

Instantly share code, notes, and snippets.

@ebuchman
Created May 18, 2017 10:31
Show Gist options
  • Save ebuchman/640d5fc6c2605f73497992fe107ebe0b to your computer and use it in GitHub Desktop.
Save ebuchman/640d5fc6c2605f73497992fe107ebe0b to your computer and use it in GitHub Desktop.
Breaking changes to functions and methods in tendermint v0.10.0
-----------------------------------------------
blockchain
-----------------------------------------------
NewBlockchainReactor
-func NewBlockchainReactor(config cfg.Config, state *sm.State, proxyAppConn proxy.AppConnConsensus, store *BlockStore, fastSync bool) *BlockchainReactor {
+func NewBlockchainReactor(state *sm.State, proxyAppConn proxy.AppConnConsensus, store *BlockStore, fastSync bool) *BlockchainReactor {
-----------------------------------------------
cmd
-----------------------------------------------
ResetAll
-func ResetAll(c cfg.Config, l log15.Logger) {
+func ResetAll(dbDir, privValFile string, logger log.Logger) {
-----------------------------------------------
consensus
-----------------------------------------------
RunReplayFile
-func RunReplayFile(config cfg.Config, walFile string, console bool) {
+func RunReplayFile(config cfg.BaseConfig, csConfig *cfg.ConsensusConfig, console bool) {
NewConsensusState
-func NewConsensusState(config cfg.Config, state *sm.State, proxyAppConn proxy.AppConnConsensus, blockStore types.BlockStore, mempool types.Mempool) *ConsensusState {
+func NewConsensusState(config *cfg.ConsensusConfig, state *sm.State, proxyAppConn proxy.AppConnConsensus, blockStore types.BlockStore, mempool types.Mempool) *ConsensusState {
NewHandshaker
-func NewHandshaker(config cfg.Config, state *sm.State, store types.BlockStore) *Handshaker {
+func NewHandshaker(state *sm.State, store types.BlockStore) *Handshaker {
NewMockBlockStore
-func NewMockBlockStore(config cfg.Config) *mockBlockStore {
+func NewMockBlockStore(config *cfg.Config) *mockBlockStore {
-----------------------------------------------
mempool
-----------------------------------------------
NewMempool
-func NewMempool(config cfg.Config, proxyAppConn proxy.AppConnMempool) *Mempool {
+func NewMempool(config *cfg.MempoolConfig, proxyAppConn proxy.AppConnMempool) *Mempool {
NewMempoolReactor
-func NewMempoolReactor(config cfg.Config, mempool *Mempool) *MempoolReactor {
+func NewMempoolReactor(config *cfg.MempoolConfig, mempool *Mempool) *MempoolReactor {
-----------------------------------------------
node
-----------------------------------------------
NewNodeDefault
-func NewNodeDefault(config cfg.Config) *Node {
+func NewNodeDefault(config *cfg.Config, logger log.Logger) *Node {
NewNode
-func NewNode(config cfg.Config, privValidator *types.PrivValidator, clientCreator proxy.ClientCreator) *Node {
+func NewNode(config *cfg.Config, privValidator *types.PrivValidator, clientCreator proxy.ClientCreator, logger log.Logger) *Node {
-----------------------------------------------
proxy
-----------------------------------------------
DefaultClientCreator
-func DefaultClientCreator(config cfg.Config) ClientCreator {
+func DefaultClientCreator(addr, transport, dbDir string) ClientCreator {
NewAppConns
-func NewAppConns(config cfg.Config, clientCreator ClientCreator, handshaker Handshaker) AppConns {
+func NewAppConns(clientCreator ClientCreator, handshaker Handshaker) AppConns {
NewMultiAppConn
-func NewMultiAppConn(config cfg.Config, clientCreator ClientCreator, handshaker Handshaker) *multiAppConn {
+func NewMultiAppConn(clientCreator ClientCreator, handshaker Handshaker) *multiAppConn {
-----------------------------------------------
rpc
-----------------------------------------------
ABCIQuery
-func ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
(c Client).ABCIQuery
-func (c Client) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (c Client) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
GetConfig
-func GetConfig() cfg.Config {
+func GetConfig() *cfg.Config {
(c *HTTP).ABCIQuery
-func (c *HTTP) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (c *HTTP) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
(a ABCIApp).ABCIQuery
-func (a ABCIApp) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (a ABCIApp) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
(r *ABCIRecorder).ABCIQuery
-func (r *ABCIRecorder) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (r *ABCIRecorder) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
(c Local).ABCIQuery
-func (c Local) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (c Local) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
(m ABCIMock).ABCIQuery
-func (m ABCIMock) ABCIQuery(path string, data []byte, prove bool) (*ctypes.ResultABCIQuery, error) {
+func (m ABCIMock) ABCIQuery(path string, data data.Bytes, prove bool) (*ctypes.ResultABCIQuery, error) {
-----------------------------------------------
state
-----------------------------------------------
ExecCommitBlock
-func ExecCommitBlock(appConnConsensus proxy.AppConnConsensus, block *types.Block) ([]byte, error) {
+func ExecCommitBlock(appConnConsensus proxy.AppConnConsensus, block *types.Block, logger log.Logger) ([]byte, error) {
GetState
-func GetState(config cfg.Config, stateDB dbm.DB) *State {
+func GetState(stateDB dbm.DB, genesisFile string) *State {
-----------------------------------------------
types
-----------------------------------------------
(b *Block).Hash
-func (b *Block) Hash() []byte {
+func (b *Block) Hash() data.Bytes {
LoadOrGenPrivValidator
-func LoadOrGenPrivValidator(filePath string) *PrivValidator {
+func LoadOrGenPrivValidator(filePath string, logger log.Logger) *PrivValidator {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment