mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 02:42:27 +00:00
cmd/swarm/swarm-smoke: fixed httpEndpoint for trigger
This commit is contained in:
parent
5b16c05479
commit
b5ec08d127
1 changed files with 4 additions and 3 deletions
|
|
@ -75,7 +75,8 @@ func triggerChunkDebug(testData []byte) error {
|
||||||
|
|
||||||
// has-chunks
|
// has-chunks
|
||||||
for _, host := range hosts {
|
for _, host := range hosts {
|
||||||
rpcClient, err := rpc.Dial(host + ":8545")
|
httpHost := fmt.Sprintf("http://%s:%d", host, 8545)
|
||||||
|
rpcClient, err := rpc.Dial(httpHost)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
@ -88,11 +89,11 @@ func triggerChunkDebug(testData []byte) error {
|
||||||
for _, info := range hasInfo {
|
for _, info := range hasInfo {
|
||||||
if !info.Has {
|
if !info.Has {
|
||||||
count++
|
count++
|
||||||
log.Error("Host does not have chunk", "host", host, "chunk", info.Addr)
|
log.Error("Host does not have chunk", "host", httpHost, "chunk", info.Addr)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if count == 0 {
|
if count == 0 {
|
||||||
log.Info("Host reported to have all chunks", "host", host)
|
log.Info("Host reported to have all chunks", "host", httpHost)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue