Skip to content

Commit

Permalink
rpc: changed logging to use glog
Browse files Browse the repository at this point in the history
  • Loading branch information
obscuren committed Apr 14, 2015
1 parent f46af45 commit d82aaf6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions rpc/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"net/http"

"github.com/ethereum/go-ethereum/logger"
"github.com/ethereum/go-ethereum/logger/glog"
"github.com/ethereum/go-ethereum/xeth"
"github.com/rs/cors"
)
Expand Down Expand Up @@ -110,7 +111,7 @@ func RpcResponse(api *EthereumApi, request *RpcRequest) *interface{} {
response = &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: request.Id, Error: jsonerr}
}

rpclogger.DebugDetailf("Generated response: %T %s", response, response)
glog.V(logger.Detail).Infof("Generated response: %T %s", response, response)
return &response
}

Expand All @@ -121,7 +122,7 @@ func send(writer io.Writer, v interface{}) (n int, err error) {
rpclogger.Fatalln("Error marshalling JSON", err)
return 0, err
}
rpclogger.DebugDetailf("Sending payload: %s", payload)
glog.V(logger.Detail).Infof("Sending payload: %s", payload)

return writer.Write(payload)
}

0 comments on commit d82aaf6

Please sign in to comment.