lint: remove dot import (go-common)

Spell out the package explicitly.
This commit is totally textual, and does not change any logic.

The swiss-army knife package may serve a kick-start in early
stage development. But as the codebase growing, we might want
to retire it gradually:

  For simple wrapping functions, just inline it on the call site.
  For larger pice of code, make it an independent package.
This commit is contained in:
Tzu-Jung Lee
2017-01-16 22:48:24 -08:00
parent c65bb21a51
commit fcaa545e1e
20 changed files with 98 additions and 99 deletions

View File

@ -9,13 +9,13 @@ import (
"sync"
"github.com/tendermint/abci/types"
. "github.com/tendermint/go-common"
common "github.com/tendermint/go-common"
)
// var maxNumberConnections = 2
type SocketServer struct {
BaseService
common.BaseService
proto string
addr string
@ -29,7 +29,7 @@ type SocketServer struct {
app types.Application
}
func NewSocketServer(protoAddr string, app types.Application) (Service, error) {
func NewSocketServer(protoAddr string, app types.Application) (common.Service, error) {
parts := strings.SplitN(protoAddr, "://", 2)
proto, addr := parts[0], parts[1]
s := &SocketServer{
@ -39,7 +39,7 @@ func NewSocketServer(protoAddr string, app types.Application) (Service, error) {
app: app,
conns: make(map[int]net.Conn),
}
s.BaseService = *NewBaseService(nil, "ABCIServer", s)
s.BaseService = *common.NewBaseService(nil, "ABCIServer", s)
_, err := s.Start() // Just start it
return s, err
}
@ -100,7 +100,7 @@ func (s *SocketServer) acceptConnectionsRoutine() {
if !s.IsRunning() {
return // Ignore error from listener closing.
}
Exit("Failed to accept connection: " + err.Error())
common.Exit("Failed to accept connection: " + err.Error())
} else {
log.Notice("Accepted a new connection")
}