Merge branch 'develop' into feature/237-tx-indexing
This commit is contained in:
commit
bf7521a6ab
6
Makefile
6
Makefile
|
@ -35,9 +35,9 @@ test100:
|
||||||
@for i in {1..100}; do make test; done
|
@for i in {1..100}; do make test; done
|
||||||
|
|
||||||
draw_deps:
|
draw_deps:
|
||||||
# requires brew install graphviz
|
# requires brew install graphviz or apt-get install graphviz
|
||||||
go get github.com/hirokidaichi/goviz
|
go get github.com/RobotsAndPencils/goviz
|
||||||
goviz -i ./cmd/tendermint | dot -Tpng -o huge.png
|
@goviz -i github.com/tendermint/tendermint/cmd/tendermint -d 3 | dot -Tpng -o dependency-graph.png
|
||||||
|
|
||||||
list_deps:
|
list_deps:
|
||||||
@go list -f '{{join .Deps "\n"}}' ./... | \
|
@go list -f '{{join .Deps "\n"}}' ./... | \
|
||||||
|
|
|
@ -10,6 +10,8 @@ https://camo.githubusercontent.com/915b7be44ada53c290eb157634330494ebe3e30a/6874
|
||||||
)](https://godoc.org/github.com/tendermint/tendermint)
|
)](https://godoc.org/github.com/tendermint/tendermint)
|
||||||
[![chat](https://img.shields.io/badge/slack-join%20chat-pink.svg)](http://forum.tendermint.com:3000/)
|
[![chat](https://img.shields.io/badge/slack-join%20chat-pink.svg)](http://forum.tendermint.com:3000/)
|
||||||
[![license](https://img.shields.io/github/license/tendermint/tendermint.svg)](https://github.com/tendermint/tendermint/blob/master/LICENSE)
|
[![license](https://img.shields.io/github/license/tendermint/tendermint.svg)](https://github.com/tendermint/tendermint/blob/master/LICENSE)
|
||||||
|
[![](https://tokei.rs/b1/github/tendermint/tendermint?category=lines)](https://github.com/tendermint/tendermint)
|
||||||
|
|
||||||
|
|
||||||
Branch | Tests | Coverage | Report Card
|
Branch | Tests | Coverage | Report Card
|
||||||
----------|-------|----------|-------------
|
----------|-------|----------|-------------
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
package core
|
package core
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"fmt"
|
||||||
|
|
||||||
ctypes "github.com/tendermint/tendermint/rpc/core/types"
|
ctypes "github.com/tendermint/tendermint/rpc/core/types"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -31,10 +33,17 @@ func NetInfo() (*ctypes.ResultNetInfo, error) {
|
||||||
|
|
||||||
// Dial given list of seeds
|
// Dial given list of seeds
|
||||||
func UnsafeDialSeeds(seeds []string) (*ctypes.ResultDialSeeds, error) {
|
func UnsafeDialSeeds(seeds []string) (*ctypes.ResultDialSeeds, error) {
|
||||||
|
|
||||||
|
if len(seeds) == 0 {
|
||||||
|
return &ctypes.ResultDialSeeds{}, fmt.Errorf("No seeds provided")
|
||||||
|
}
|
||||||
// starts go routines to dial each seed after random delays
|
// starts go routines to dial each seed after random delays
|
||||||
log.Info("DialSeeds", "addrBook", addrBook, "seeds", seeds)
|
log.Info("DialSeeds", "addrBook", addrBook, "seeds", seeds)
|
||||||
err := p2pSwitch.DialSeeds(addrBook, seeds)
|
err := p2pSwitch.DialSeeds(addrBook, seeds)
|
||||||
return &ctypes.ResultDialSeeds{}, err
|
if err != nil {
|
||||||
|
return &ctypes.ResultDialSeeds{}, err
|
||||||
|
}
|
||||||
|
return &ctypes.ResultDialSeeds{"Dialing seeds in progress. See /net_info for details"}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
|
@ -60,6 +60,7 @@ type ResultNetInfo struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResultDialSeeds struct {
|
type ResultDialSeeds struct {
|
||||||
|
Log string `json:"log"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type Peer struct {
|
type Peer struct {
|
||||||
|
|
Loading…
Reference in New Issue