aboutsummaryrefslogtreecommitdiffstats
path: root/rpc/json.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-02-23 22:49:05 +0800
committerGitHub <noreply@github.com>2017-02-23 22:49:05 +0800
commit357732a8404c9fe4d02f041d20a0d05381a3e6d1 (patch)
treeedaf8a63eb7f7434cd9b9cbd764b3c4c3d76191e /rpc/json.go
parent29fac7de448c85049a97cbec3dc0819122bd2cb0 (diff)
parentf89dd627760b43bd405cb3db1e5efdb100835db5 (diff)
downloaddexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.gz
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.bz2
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.lz
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.xz
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.zst
dexon-357732a8404c9fe4d02f041d20a0d05381a3e6d1.zip
Merge pull request #3696 from karalabe/contextual-logger
Contextual logger
Diffstat (limited to 'rpc/json.go')
-rw-r--r--rpc/json.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/rpc/json.go b/rpc/json.go
index 61a4ddf43..c777fab6e 100644
--- a/rpc/json.go
+++ b/rpc/json.go
@@ -26,8 +26,7 @@ import (
"strings"
"sync"
- "github.com/ethereum/go-ethereum/logger"
- "github.com/ethereum/go-ethereum/logger/glog"
+ "github.com/ethereum/go-ethereum/log"
)
const (
@@ -171,7 +170,7 @@ func parseRequest(incomingMsg json.RawMessage) ([]rpcRequest, bool, Error) {
// first param must be subscription name
var subscribeMethod [1]string
if err := json.Unmarshal(in.Payload, &subscribeMethod); err != nil {
- glog.V(logger.Debug).Infof("Unable to parse subscription method: %v\n", err)
+ log.Debug(fmt.Sprintf("Unable to parse subscription method: %v\n", err))
return nil, false, &invalidRequestError{"Unable to parse subscription request"}
}
@@ -224,7 +223,7 @@ func parseBatchRequest(incomingMsg json.RawMessage) ([]rpcRequest, bool, Error)
// first param must be subscription name
var subscribeMethod [1]string
if err := json.Unmarshal(r.Payload, &subscribeMethod); err != nil {
- glog.V(logger.Debug).Infof("Unable to parse subscription method: %v\n", err)
+ log.Debug(fmt.Sprintf("Unable to parse subscription method: %v\n", err))
return nil, false, &invalidRequestError{"Unable to parse subscription request"}
}