Merge pull request #766 from filecoin-project/feat/holes

Pre-sealing holes
This commit is contained in:
Łukasz Magiera
2019-12-07 10:29:17 +01:00
committed by GitHub
7 changed files with 29 additions and 19 deletions
+4 -1
View File
@@ -119,12 +119,14 @@ type Config struct {
SectorSize uint64
Miner address.Address
WorkerThreads uint8
WorkerThreads uint8
FallbackLastID uint64
CacheDir string
SealedDir string
StagedDir string
UnsealedDir string
_ struct{} // guard against nameless init
}
func New(cfg *Config, ds dtypes.MetadataDS) (*SectorBuilder, error) {
@@ -151,6 +153,7 @@ func New(cfg *Config, ds dtypes.MetadataDS) (*SectorBuilder, error) {
}
lastUsedID = uint64(i)
case datastore.ErrNotFound:
lastUsedID = cfg.FallbackLastID
default:
return nil, err
}