feat: refactor: actor bundling system (#8838)
1. Include the builtin-actors in the lotus source tree.
2. Embed the bundle on build instead of downloading at runtime.
3. Avoid reading the bundle whenever possible by including bundle
metadata (the bundle CID, the actor CIDs, etc.).
4. Remove everything related to dependency injection.
1. We're no longer downloading the bundle, so doing anything ahead
of time doesn't really help.
2. We register the manifests on init because, unfortunately, they're
global.
3. We explicitly load the current actors bundle in the genesis
state-tree method.
4. For testing, we just change the in-use bundle with a bit of a
hack. It's not great, but using dependency injection doesn't make
any sense either because, again, the manifest information is
global.
5. Remove the bundle.toml file. Bundles may be overridden by
specifying an override path in the parameters file, or an
environment variable.
fixes #8701
This commit is contained in:
@@ -48,13 +48,6 @@ var ChainNode = Options(
|
||||
// Full node or lite node
|
||||
// TODO: Fix offline mode
|
||||
|
||||
// FVM: builtin actor bundle loading
|
||||
// Note: this has to load before the upgrade schedule, so that we can patch in the
|
||||
// right manifest cid.
|
||||
// This restriction will be lifted once we have the final actors v8 bundle and we know
|
||||
// the manifest cid.
|
||||
Override(new(dtypes.BuiltinActorsLoaded), modules.LoadBuiltinActors),
|
||||
|
||||
// Consensus settings
|
||||
Override(new(dtypes.DrandSchedule), modules.BuiltinDrandConfig),
|
||||
Override(new(stmgr.UpgradeSchedule), modules.UpgradeSchedule),
|
||||
|
||||
Reference in New Issue
Block a user