Merge pull request #8353 from filecoin-project/fix/ru-retry-loop
fix: sealing: always do cooldown in handleSubmitReplicaUpdateFailed
This commit is contained in:
commit
1a0fc75325
4
extern/storage-sealing/input.go
vendored
4
extern/storage-sealing/input.go
vendored
@ -473,6 +473,8 @@ func (m *Sealing) updateInput(ctx context.Context, sp abi.RegisteredSealProof) e
|
||||
return matches[i].sector.Number < matches[j].sector.Number // prefer older sectors
|
||||
})
|
||||
|
||||
log.Debugw("updateInput matching", "matches", len(matches), "toAssign", len(toAssign), "openSectors", len(m.openSectors), "pieces", len(m.pendingPieces))
|
||||
|
||||
var assigned int
|
||||
for _, mt := range matches {
|
||||
if m.pendingPieces[mt.deal].assigned {
|
||||
@ -506,6 +508,8 @@ func (m *Sealing) updateInput(ctx context.Context, sp abi.RegisteredSealProof) e
|
||||
}
|
||||
}
|
||||
|
||||
log.Debugw("updateInput matching done", "matches", len(matches), "toAssign", len(toAssign), "assigned", assigned, "openSectors", len(m.openSectors), "pieces", len(m.pendingPieces))
|
||||
|
||||
if len(toAssign) > 0 {
|
||||
log.Errorf("we are trying to create a new sector with open sectors %v", m.openSectors)
|
||||
if err := m.tryGetDealSector(ctx, sp, expF); err != nil {
|
||||
|
12
extern/storage-sealing/states_failed.go
vendored
12
extern/storage-sealing/states_failed.go
vendored
@ -184,14 +184,14 @@ func (m *Sealing) handleComputeProofFailed(ctx statemachine.Context, sector Sect
|
||||
}
|
||||
|
||||
func (m *Sealing) handleSubmitReplicaUpdateFailed(ctx statemachine.Context, sector SectorInfo) error {
|
||||
if err := failedCooldown(ctx, sector); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if sector.ReplicaUpdateMessage != nil {
|
||||
mw, err := m.Api.StateSearchMsg(ctx.Context(), *sector.ReplicaUpdateMessage)
|
||||
if err != nil {
|
||||
// API error
|
||||
if err := failedCooldown(ctx, sector); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return ctx.Send(SectorRetrySubmitReplicaUpdateWait{})
|
||||
}
|
||||
|
||||
@ -248,10 +248,6 @@ func (m *Sealing) handleSubmitReplicaUpdateFailed(ctx statemachine.Context, sect
|
||||
return ctx.Send(SectorAbortUpgrade{})
|
||||
}
|
||||
|
||||
if err := failedCooldown(ctx, sector); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return ctx.Send(SectorRetrySubmitReplicaUpdate{})
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user