fix: miner info: Show correct sector state counts
This commit is contained in:
parent
1ca071ef77
commit
3407848e8c
@ -4,6 +4,7 @@
|
|||||||
- chore: Auto remove local chain data when importing chain file or snapshot ([filecoin-project/lotus#11277](https://github.com/filecoin-project/lotus/pull/11277))
|
- chore: Auto remove local chain data when importing chain file or snapshot ([filecoin-project/lotus#11277](https://github.com/filecoin-project/lotus/pull/11277))
|
||||||
- feat: metric: export Mpool message count ([filecoin-project/lotus#11361](https://github.com/filecoin-project/lotus/pull/11361))
|
- feat: metric: export Mpool message count ([filecoin-project/lotus#11361](https://github.com/filecoin-project/lotus/pull/11361))
|
||||||
- feat: sealing: load SectorsSummary from sealing SectorStats instead of calling API each time ([filecoin-project/lotus#11353](https://github.com/filecoin-project/lotus/pull/11353))
|
- feat: sealing: load SectorsSummary from sealing SectorStats instead of calling API each time ([filecoin-project/lotus#11353](https://github.com/filecoin-project/lotus/pull/11353))
|
||||||
|
- fix: miner info: Show correct sector state counts ([filecoin-project/lotus#11456](https://github.com/filecoin-project/lotus/pull/11456))
|
||||||
|
|
||||||
## Improvements
|
## Improvements
|
||||||
- fix: Add time slicing to splitstore purging step during compaction to reduce lock congestion [filecoin-project/lotus#11269](https://github.com/filecoin-project/lotus/pull/11269)
|
- fix: Add time slicing to splitstore purging step during compaction to reduce lock congestion [filecoin-project/lotus#11269](https://github.com/filecoin-project/lotus/pull/11269)
|
||||||
|
@ -44,6 +44,10 @@ func (ss *SectorStats) updateSector(ctx context.Context, cfg sealiface.Config, i
|
|||||||
ss.totals[toStatState(oldst, cfg.FinalizeEarly)]--
|
ss.totals[toStatState(oldst, cfg.FinalizeEarly)]--
|
||||||
ss.byState[oldst]--
|
ss.byState[oldst]--
|
||||||
|
|
||||||
|
if ss.byState[oldst] <= 0 {
|
||||||
|
delete(ss.byState, oldst)
|
||||||
|
}
|
||||||
|
|
||||||
mctx, _ := tag.New(ctx, tag.Upsert(metrics.SectorState, string(oldst)))
|
mctx, _ := tag.New(ctx, tag.Upsert(metrics.SectorState, string(oldst)))
|
||||||
stats.Record(mctx, metrics.SectorStates.M(ss.byState[oldst]))
|
stats.Record(mctx, metrics.SectorStates.M(ss.byState[oldst]))
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user