diff --git a/extern/sector-storage/manager.go b/extern/sector-storage/manager.go index 385f8175b..f9ebc083c 100644 --- a/extern/sector-storage/manager.go +++ b/extern/sector-storage/manager.go @@ -244,7 +244,7 @@ func (m *Manager) SectorsUnsealPiece(ctx context.Context, sector storage.SectorR // save us some work in case another piece is requested from here log.Debugf("unseal sector %d", sector.ID) - // Note: This unsealed call will essentially become a no-op of the worker already has an Unsealed sector file for the given sector. + // Note: This unseal piece call will essentially become a no-op if the worker already has an Unsealed sector file for the given sector. _, err := m.waitSimpleCall(ctx)(w.UnsealPiece(ctx, sector, 0, abi.PaddedPieceSize(ssize).Unpadded(), ticket, *unsealed)) log.Debugf("completed unseal sector %d", sector.ID) return err diff --git a/extern/sector-storage/piece_provider.go b/extern/sector-storage/piece_provider.go index f4e7439cd..acc799273 100644 --- a/extern/sector-storage/piece_provider.go +++ b/extern/sector-storage/piece_provider.go @@ -43,7 +43,7 @@ func NewPieceProvider(storage *stores.Remote, index stores.SectorIndex, uns Unse // tryReadUnsealedPiece will try to read the unsealed piece from an existing unsealed sector file for the given sector from any worker that has it. // It will NOT try to schedule an Unseal of a sealed sector file for the read. // -// Will return a nil reader if the piece does NOT exist in any unsealed file/there is not unsealed file for the given sector on any of the workers. +// Returns a nil reader if the piece does NOT exist in any unsealed file or there is no unsealed file for the given sector on any of the workers. func (p *pieceProvider) tryReadUnsealedPiece(ctx context.Context, sector storage.SectorRef, offset storiface.UnpaddedByteIndex, size abi.UnpaddedPieceSize) (io.ReadCloser, context.CancelFunc, error) { // acquire a lock purely for reading unsealed sectors ctx, cancel := context.WithCancel(ctx) diff --git a/extern/sector-storage/stores/http_handler.go b/extern/sector-storage/stores/http_handler.go index 813943fac..fef054e7b 100644 --- a/extern/sector-storage/stores/http_handler.go +++ b/extern/sector-storage/stores/http_handler.go @@ -249,7 +249,7 @@ func (handler *FetchHandler) remoteGetAllocated(w http.ResponseWriter, r *http.R } defer func() { if err := pf.Close(); err != nil { - log.Error("close partial file: ", err) + log.Error("closing partial file: ", err) } }() diff --git a/extern/sector-storage/stores/remote.go b/extern/sector-storage/stores/remote.go index 2d409268b..dc556ad92 100644 --- a/extern/sector-storage/stores/remote.go +++ b/extern/sector-storage/stores/remote.go @@ -532,7 +532,7 @@ func (r *Remote) Reader(ctx context.Context, s storage.SectorRef, offset, size a continue } - // readRemote fetches a reader that we can used to read the unsealed piece from the remote worker. + // readRemote fetches a reader that we can use to read the unsealed piece from the remote worker. // It uses a ranged HTTP query to ensure we ONLY read the unsealed piece and not the entire unsealed file. rd, err = r.readRemote(ctx, url, offset, size) if err != nil {