summaryrefslogtreecommitdiffhomepage
path: root/server/server.go
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2014-12-22 05:19:07 -0800
committerFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2014-12-22 05:19:07 -0800
commit13e9aefa1d7ec92600d46a004d5f38a4ff95ac7e (patch)
treeb88dd27679b4a891bd6218498123811ab0d85596 /server/server.go
parenta5874d6912e2286fa5af5dc452e3d99ebc38c7a5 (diff)
add --log-json command line option
During development, it's easy to parse a plain format by human. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Diffstat (limited to 'server/server.go')
-rw-r--r--server/server.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/server.go b/server/server.go
index 01daa23a..f3ed0092 100644
--- a/server/server.go
+++ b/server/server.go
@@ -93,10 +93,10 @@ func (server *BgpServer) Serve() {
remoteAddr := strings.Split(conn.RemoteAddr().String(), ":")[0]
peer, found := server.peerMap[remoteAddr]
if found {
- log.Info("accepted a new passive connection for", remoteAddr)
+ log.Info("accepted a new passive connection from ", remoteAddr)
peer.PassConn(conn)
} else {
- log.Info("can't find configuration for a new passive connection", remoteAddr)
+ log.Info("can't find configuration for a new passive connection from ", remoteAddr)
conn.Close()
}
case peer := <-server.addedPeerCh:
@@ -109,11 +109,11 @@ func (server *BgpServer) Serve() {
SetTcpMD5SigSockopts(int(f.Fd()), addr, "")
p, found := server.peerMap[addr]
if found {
- log.Info("Delete a peer configuration for", addr)
+ log.Info("Delete a peer configuration for ", addr)
p.Stop()
delete(server.peerMap, addr)
} else {
- log.Info("Can't delete a peer configuration for", addr)
+ log.Info("Can't delete a peer configuration for ", addr)
}
case restReq := <-server.RestReqCh:
server.handleRest(restReq)