Browse Source

Try to fix logging bug

pull/64/head
Duke 1 month ago
parent
commit
4c0806d39c
  1. 4
      common/common.go
  2. 2
      frontend/service.go

4
common/common.go

@ -283,7 +283,7 @@ func CallRpcWithRetries(method string, params []json.RawMessage) (json.RawMessag
result, err := RawRequest(method, params) result, err := RawRequest(method, params)
if err == nil { if err == nil {
if retryCount > 0 { if retryCount > 0 {
Log.Warn(fmt.Sprintf("%s RPC successful"), method) Log.Warn(fmt.Sprintf("%s RPC successful", method))
} }
return result, err return result, err
break break
@ -292,7 +292,7 @@ func CallRpcWithRetries(method string, params []json.RawMessage) (json.RawMessag
if retryCount > maxRetries { if retryCount > maxRetries {
Log.WithFields(logrus.Fields{ Log.WithFields(logrus.Fields{
"timeouts": retryCount, "timeouts": retryCount,
}).Fatal(fmt.Sprintf("unable to issue %s RPC call to hushd node"), method) }).Fatal(fmt.Sprintf("unable to issue %s RPC call to hushd node", method))
} }
Log.WithFields(logrus.Fields{ Log.WithFields(logrus.Fields{
"error": err.Error(), "error": err.Error(),

2
frontend/service.go

@ -258,7 +258,7 @@ func (s *lwdStreamer) GetCoinsupply(ctx context.Context, in *walletrpc.Empty) (*
}, nil }, nil
} }
// SendTransaction forwards raw transaction bytes to a zcashd instance over JSON-RPC // SendTransaction forwards raw transaction bytes to a full node over JSON-RPC
func (s *lwdStreamer) SendTransaction(ctx context.Context, rawtx *walletrpc.RawTransaction) (*walletrpc.SendResponse, error) { func (s *lwdStreamer) SendTransaction(ctx context.Context, rawtx *walletrpc.RawTransaction) (*walletrpc.SendResponse, error) {
// sendrawtransaction "hexstring" ( allowhighfees ) // sendrawtransaction "hexstring" ( allowhighfees )
// //

Loading…
Cancel
Save