filecoin-project / go-data-transfer

Data Transfer Shared Component for go-filecoin & go-lotus
Other
39 stars 17 forks source link

Stalled transfers should not have 'Ongoing' status #149

Open whyrusleeping opened 3 years ago

whyrusleeping commented 3 years ago

Currently, if the other peer in a data transfer channel disconnects and causes the transfer to stall, the channel retains its Ongoing status, and the channels status message gets set to "other peer appears to have hung up. restart Channel".

This implies that we know we need to restart the channel, but dont do anything about it, and if any automated processes want to do something about it, they need to do string parsing to tell this. I think that this state deserves its own channel state value.

dirkmc commented 3 years ago

I think the solution here is that the data transfer should attempt to restart the stalled channel automatically.

We have code to do automatic restarts but it's still a little buggy. In order to see what the transfer is doing (and whether it's trying to restart) you can set the following logs to the debug level: