Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Storage provider design and documentation #56

Merged
merged 82 commits into from
Jul 2, 2024

Conversation

aidan46
Copy link
Contributor

@aidan46 aidan46 commented May 30, 2024

Description

Add the Storage Provider pallet and implement its Config trait on substrate Runtime. Despite its name, it does not handle any storage operations, this pallet is the interface for storage providers (the binary handling storage operations).

Important points for reviewers

This pallet is based on the Storage Miner Actor from Filecoin. Documentation for this actor can be found here and the Filecoin implementation of this actor can be found here

Checklist

  • Are there important points that reviewers should know?
    • If yes, which ones?
  • Make sure that you describe what this change does.
  • If there are follow-ups, have you created issues for them?
    • If yes, which ones? / List them here
  • Have you tested this solution?
  • Were there any alternative implementations considered?
  • Did you document new (or modified) APIs?

Set up scaffolding for the storage provider for miner indexing. This
includes function definitions and events emitted.
@aidan46 aidan46 linked an issue May 30, 2024 that may be closed by this pull request
@aidan46 aidan46 self-assigned this May 30, 2024
@aidan46 aidan46 added the enhancement New feature or request label May 30, 2024
Copy link
Contributor

@th7nder th7nder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a little bit confused (from the high-level), probably because I lack knowledge - how those worker/owner things are supposed to work and do we even need them now.

pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
Justfile Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
@aidan46 aidan46 force-pushed the feat-13-storage-provider-pallet-implementation branch from 057f38e to 6ca40cf Compare May 30, 2024 13:08
Since the storage providers will handle their own worker addresses it is
not needed to include the worker addresses in the pallet implementation.
In the Storage Provider pallet implement the logic needed to for the
`change_peer_id` function.
In the Storage Provider pallet implement the logic needed to for the
`change_owner_address` function.
Implement `create_storage_provider`, `change_peer_id` and
`change_owner_address` functions in the Storage Provider pallet.
pallets/storage-provider/Cargo.toml Outdated Show resolved Hide resolved
pallets/storage-provider/Cargo.toml Outdated Show resolved Hide resolved
pallets/storage-provider/DESIGN.md Outdated Show resolved Hide resolved
pallets/storage-provider/README.md Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Outdated Show resolved Hide resolved
pallets/storage-provider/src/lib.rs Show resolved Hide resolved
@aidan46 aidan46 added ready for review Review is needed and removed ready for review Review is needed labels Jun 25, 2024
jmg-duarte
jmg-duarte previously approved these changes Jun 25, 2024
th7nder
th7nder previously approved these changes Jun 25, 2024
serg-temchenko
serg-temchenko previously approved these changes Jun 27, 2024
th7nder
th7nder previously approved these changes Jun 27, 2024
jmg-duarte
jmg-duarte previously approved these changes Jun 27, 2024
Copy link
Collaborator

@jmg-duarte jmg-duarte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpicks and a question. Overall I think we can move this forward and change if/when necessary.

runtime/src/configs/mod.rs Show resolved Hide resolved
pallets/storage-provider/DESIGN.md Outdated Show resolved Hide resolved
pallets/storage-provider/DESIGN.md Show resolved Hide resolved
pallets/storage-provider/PROOF-OF-STORAGE.md Outdated Show resolved Hide resolved
@aidan46 aidan46 dismissed stale reviews from jmg-duarte and th7nder via dea3b90 June 27, 2024 15:18
@th7nder th7nder added ready for review Review is needed and removed ready for review Review is needed labels Jun 28, 2024
@th7nder th7nder added ready for review Review is needed and removed ready for review Review is needed labels Jul 2, 2024
@aidan46 aidan46 merged commit 0377463 into develop Jul 2, 2024
3 checks passed
@aidan46 aidan46 deleted the feat-13-storage-provider-pallet-implementation branch July 2, 2024 08:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ready for review Review is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants