Skip to content

Commit

Permalink
Merge pull request #6235 from filecoin-project/feat/fip-0013
Browse files Browse the repository at this point in the history
WIP: Integrate FIP0013
  • Loading branch information
magik6k authored May 26, 2021
2 parents b19d6cd + fc76a09 commit 2b93bcd
Show file tree
Hide file tree
Showing 67 changed files with 4,071 additions and 414 deletions.
10 changes: 10 additions & 0 deletions api/api_storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,16 @@ type StorageMiner interface {
// SectorTerminatePending returns a list of pending sector terminations to be sent in the next batch message
SectorTerminatePending(ctx context.Context) ([]abi.SectorID, error) //perm:admin
SectorMarkForUpgrade(ctx context.Context, id abi.SectorNumber) error //perm:admin
// SectorPreCommitFlush immediately sends a PreCommit message with sectors batched for PreCommit.
// Returns null if message wasn't sent
SectorPreCommitFlush(ctx context.Context) (*cid.Cid, error) //perm:admin
// SectorPreCommitPending returns a list of pending PreCommit sectors to be sent in the next batch message
SectorPreCommitPending(ctx context.Context) ([]abi.SectorID, error) //perm:admin
// SectorCommitFlush immediately sends a Commit message with sectors aggregated for Commit.
// Returns null if message wasn't sent
SectorCommitFlush(ctx context.Context) (*cid.Cid, error) //perm:admin
// SectorCommitPending returns a list of pending Commit sectors to be sent in the next aggregate message
SectorCommitPending(ctx context.Context) ([]abi.SectorID, error) //perm:admin

// WorkerConnect tells the node to connect to workers RPC
WorkerConnect(context.Context, string) error //perm:admin retry:true
Expand Down
24 changes: 24 additions & 0 deletions api/apistruct/struct.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/test/deadlines.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func TestDeadlineToggling(t *testing.T, b APIBuilder, blocktime time.Duration) {
ctx, cancel := context.WithCancel(context.Background())
defer cancel()

n, sn := b(t, []FullNodeOpts{FullNodeWithLatestActorsAt(upgradeH)}, OneMiner)
n, sn := b(t, []FullNodeOpts{FullNodeWithV4ActorsAt(upgradeH)}, OneMiner)

client := n[0].FullNode.(*impl.FullNodeAPI)
minerA := sn[0]
Expand Down
2 changes: 2 additions & 0 deletions api/test/deals.go
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,8 @@ func startSealingWaiting(t *testing.T, ctx context.Context, miner TestStorageNod
require.NoError(t, miner.SectorStartSealing(ctx, snum))
}
}

flushSealingBatches(t, ctx, miner)
}

func testRetrieval(t *testing.T, ctx context.Context, client api.FullNode, fcid cid.Cid, piece *cid.Cid, carExport bool, data []byte) {
Expand Down
Loading

0 comments on commit 2b93bcd

Please sign in to comment.