-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
cleanup: miner: remove markets and deal-making from Lotus Miner #12005
base: feat/remove-markets-client
Are you sure you want to change the base?
cleanup: miner: remove markets and deal-making from Lotus Miner #12005
Conversation
All checks have passed |
You can (and imo should) remove the graphsync module from the fullnode with markets gone. There are comments saying it's used by other subsystems but it's just markets afaik. |
@ZenGround0 Yup. You will see it all in the final draft once it is ready for review :) |
Tested this on a local devnet node and things look good. Was able to seal and activate sectors (submit WindowPosts for them)
|
… feat/remove-markets-provider
return xerrors.Errorf("at least one module must be enabled") | ||
} | ||
|
||
// we should remove this as soon as we have more service types and not just `markets` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hah!
Fees MinerFeeConfig | ||
Addresses MinerAddressConfig | ||
HarmonyDB HarmonyDB | ||
EnableLibp2p bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we even need this anymore? can we just force a false
when we call ConfigCommon()
because it's not used anywhere else in miner is it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
connects one full node to the provided full nodes
not the miners though, only full nodes
node/builder_miner.go
Outdated
return Options( | ||
|
||
Override(new(v1api.FullNode), modules.MakeUuidWrapper), | ||
// Needed to instantiate pubsub used by index provider via ConfigCommon | ||
Override(new(dtypes.DrandSchedule), modules.BuiltinDrandConfig), | ||
Override(new(dtypes.BootstrapPeers), modules.BuiltinBootstrap), | ||
Override(new(dtypes.DrandBootstrap), modules.DrandBootstrap), | ||
ConfigCommon(&cfg.Common, enableLibp2pNode), | ||
ConfigCommon(&cfg.Common, cfg.EnableLibp2p), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ConfigCommon(&cfg.Common, cfg.EnableLibp2p), | |
ConfigCommon(&cfg.Common, false), |
As per comment below, I don't think we need this option, it doesn't need a host to listen for anything anymore does it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rvagg We need this flag as enabling this flag allows Miners to talk to the deamon over libp2p in the testkit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't they use RPC though? the miners need to talk together but I thought the rest was all just RPC
Transport dtypes.ProviderTransport `optional:"true"` | ||
DealPublisher *storageadapter.DealPublisher `optional:"true"` | ||
SectorBlocks *sectorblocks.SectorBlocks `optional:"true"` | ||
Host host.Host `optional:"true"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
another hint at not needing libp2p in the miner
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See my comment below.
Can't comment inline but there's also these:
|
Looks pretty good to me! Again I'd like to have Curio ppl input on this because there's some scary big changes in here, although they look right to my not-so-trained-eye. |
… feat/remove-markets-provider
@rvagg Rebased on master/parent branch and addressed your review comments. |
cfg.Subsystems.EnableMining = m.options.subsystems.Has(SMining) | ||
cfg.Subsystems.EnableSealing = m.options.subsystems.Has(SSealing) | ||
cfg.Subsystems.EnableSectorStorage = m.options.subsystems.Has(SSectorStorage) | ||
cfg.Subsystems.EnableSectorIndexDB = m.options.subsystems.Has(SHarmony) | ||
cfg.Dealmaking.MaxStagingDealsBytes = m.options.maxStagingDealsBytes | ||
cfg.EnableLibp2p = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this right? it's false
elsewhere by default now, can we remove this or switch it off and false
the second argument to node.StorageMiner()
below like it is for normal node instantiation?
I'm unsure what the libp2p functionality is for in the miner with markets gone now, maybe it can go all together, including that second argument to node.StorageMiner()
?
lgtm except I'm still not convinced on the libp2p thing, and that it's even needed on a storage node. or is it the case that in the testkit you can have a node that is both a full node and miner? but if it's a full node, it should have its own libp2p stack from the full node assembly process; where is libp2p getting involved in any of the storage miner work now? |
Related Issues
Closes #12004
Proposed Changes
The use of legacy markets was deprecated from Lotus Miner a long time ago in favour of Boost. This PR removes all legacy markets related code from the Lotus Miner. Lotus no longer depends on
go-graphsync
,go-data-transfer
,go-fil-markets
,dagstore
andindex-provider
.All Markets related functionality has been removed from the Lotus Miner CLI and the API. Specifically, the following Market APIs have been removed from a Lotus Miner API as part of this PR:
However, the following APIs have still been kept around to enable users to interact with the built-in Market Actor.
Additional Info
Checklist
Before you mark the PR ready for review, please make sure that:
<PR type>: <area>: <change being made>
fix: mempool: Introduce a cache for valid signatures
PR type
: fix, feat, build, chore, ci, docs, perf, refactor, revert, style, testarea
, e.g. api, chain, state, market, mempool, multisig, networking, paych, proving, sealing, wallet, deps