Browse Source

Warn on proxy hash mismatch, not fail

pull/206/merge
Jae Kwon 8 years ago
parent
commit
c3980cb165
2 changed files with 3 additions and 2 deletions
  1. +2
    -1
      node/node.go
  2. +1
    -1
      proxy/remote_app_conn.go

+ 2
- 1
node/node.go View File

@ -250,6 +250,7 @@ func getProxyApp(addr string, hash []byte) (proxyAppConn proxy.AppConn) {
mtx := new(sync.Mutex)
proxyAppConn = proxy.NewLocalAppConn(mtx, app)
default:
// Run forever in a loop
remoteApp, err := proxy.NewRemoteAppConn(addr)
if err != nil {
Exit(Fmt("Failed to connect to proxy for mempool: %v", err))
@ -263,7 +264,7 @@ func getProxyApp(addr string, hash []byte) (proxyAppConn proxy.AppConn) {
PanicCrisis(Fmt("Error in getting proxyAppConn hash: %v", res))
}
if !bytes.Equal(hash, res.Data) {
PanicCrisis(Fmt("ProxyApp hash does not match. Expected %X, got %X", hash, res.Data))
log.Warn(Fmt("ProxyApp hash does not match. Expected %X, got %X", hash, res.Data))
}
return proxyAppConn


+ 1
- 1
proxy/remote_app_conn.go View File

@ -12,7 +12,7 @@ type remoteAppConn struct {
}
func NewRemoteAppConn(addr string) (*remoteAppConn, error) {
client, err := tmspcli.NewClient(addr)
client, err := tmspcli.NewClient(addr, false)
if err != nil {
return nil, err
}


Loading…
Cancel
Save