Documentation
¶
Index ¶
- Constants
- Variables
- func GetDefaultUpgradeHandlerVersion() string
- func GetMaccPerms() map[string][]string
- func GetSimulatorFlags()
- func InitGenesisModuleList() []string
- func MakeEncodingConfig() ethermint.EncodingConfig
- func NewConfigFromFlags() simulation.Config
- func RegisterSwaggerAPI(_ client.Context, rtr *mux.Router)
- func SetupHandlers(app *App)
- type App
- func (app *App) AppCodec() codec.Codec
- func (app *App) AutoCliOpts() autocli.AppOptions
- func (app *App) BasicManager() module.BasicManager
- func (app *App) BeginBlocker(ctx sdk.Context) (sdk.BeginBlock, error)
- func (app *App) BlockedAddrs() map[string]bool
- func (app *App) EndBlocker(ctx sdk.Context) (sdk.EndBlock, error)
- func (app *App) ExportAppStateAndValidators(forZeroHeight bool, jailAllowedAddrs []string, modulesToExport []string) (servertypes.ExportedApp, error)
- func (app *App) GetKey(storeKey string) *storetypes.KVStoreKey
- func (app *App) GetMemKey(storeKey string) *storetypes.MemoryStoreKey
- func (app *App) GetSubspace(moduleName string) paramstypes.Subspace
- func (app *App) GetTKey(storeKey string) *storetypes.TransientStoreKey
- func (app *App) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error)
- func (app *App) InterfaceRegistry() types.InterfaceRegistry
- func (app *App) LegacyAmino() *codec.LegacyAmino
- func (app *App) LoadHeight(height int64) error
- func (app *App) ModuleAccountAddrs() map[string]bool
- func (app *App) ModuleManager() *module.Manager
- func (app *App) Name() string
- func (app *App) PreBlocker(ctx sdk.Context, _ *abci.RequestFinalizeBlock) (*sdk.ResponsePreBlock, error)
- func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig)
- func (app *App) RegisterNodeService(clientCtx client.Context, cfg config.Config)
- func (app *App) RegisterTendermintService(clientCtx client.Context)
- func (app *App) RegisterTxService(clientCtx client.Context)
- func (app *App) SimulationManager() *module.SimulationManager
- type GenesisState
Constants ¶
const Name = "zetacore"
Variables ¶
var ( NodeDir = ".zetacored" DefaultNodeHome = os.ExpandEnv("$HOME/") + NodeDir TransactionGasLimit uint64 = 10_000_000 )
var ( FlagGenesisFileValue string FlagParamsFileValue string FlagExportParamsPathValue string FlagExportParamsHeightValue int FlagExportStatePathValue string FlagExportStatsPathValue string FlagSeedValue int64 FlagInitialBlockHeightValue int FlagNumBlocksValue int FlagBlockSizeValue int FlagLeanValue bool FlagCommitValue bool FlagOnOperationValue bool // TODO: Remove in favor of binary search for invariant violation FlagAllInvariantsValue bool FlagEnabledValue bool FlagVerboseValue bool FlagPeriodValue uint FlagGenesisTimeValue int64 )
List of available flags for the simulator
var ModuleBasics = module.NewBasicManager( auth.AppModuleBasic{}, genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator), bank.AppModuleBasic{}, staking.AppModuleBasic{}, distr.AppModuleBasic{}, gov.NewAppModuleBasic(getGovProposalHandlers()), params.AppModuleBasic{}, crisis.AppModuleBasic{}, slashing.AppModuleBasic{}, upgrade.AppModuleBasic{}, evidence.AppModuleBasic{}, vesting.AppModuleBasic{}, consensus.AppModuleBasic{}, evm.AppModuleBasic{}, feemarket.AppModuleBasic{}, authoritymodule.AppModuleBasic{}, lightclientmodule.AppModuleBasic{}, crosschainmodule.AppModuleBasic{}, observermodule.AppModuleBasic{}, fungiblemodule.AppModuleBasic{}, emissionsmodule.AppModuleBasic{}, groupmodule.AppModuleBasic{}, authzmodule.AppModuleBasic{}, )
ModuleBasics defines the module BasicManager that is in charge of setting up basic, non-dependant module elements, such as codec registration and genesis verification. https://github.com/zeta-chain/node/issues/3021 TODO: Use app.mm to create the basic manager instead
Functions ¶
func GetDefaultUpgradeHandlerVersion ¶
func GetDefaultUpgradeHandlerVersion() string
GetDefaultUpgradeHandlerVersion prints the default upgrade handler version
There may be multiple upgrade handlers configured on some releases if different migrations needto be run in different environment
func GetMaccPerms ¶
GetMaccPerms returns a copy of the module account permissions
func GetSimulatorFlags ¶
func GetSimulatorFlags()
GetSimulatorFlags gets the values of all the available simulation flags
func InitGenesisModuleList ¶
func InitGenesisModuleList() []string
InitGenesisModuleList returns the module list for genesis initialization NOTE: Capability module must occur first so that it can initialize any capabilities TODO: enable back IBC all commented lines in this function are modules related to IBC https://github.com/zeta-chain/node/issues/2573
func MakeEncodingConfig ¶
func MakeEncodingConfig() ethermint.EncodingConfig
MakeEncodingConfig creates an EncodingConfig
func NewConfigFromFlags ¶
func NewConfigFromFlags() simulation.Config
NewConfigFromFlags creates a simulation from the retrieved values of the flags.
func RegisterSwaggerAPI ¶
RegisterSwaggerAPI registers swagger route with API Server
func SetupHandlers ¶
func SetupHandlers(app *App)
Types ¶
type App ¶
type App struct { *baseapp.BaseApp // sdk keepers AccountKeeper authkeeper.AccountKeeper BankKeeper bankkeeper.Keeper //CapabilityKeeper *capabilitykeeper.Keeper StakingKeeper *stakingkeeper.Keeper SlashingKeeper slashingkeeper.Keeper DistrKeeper distrkeeper.Keeper GovKeeper govkeeper.Keeper CrisisKeeper crisiskeeper.Keeper UpgradeKeeper *upgradekeeper.Keeper ParamsKeeper paramskeeper.Keeper //IBCKeeper *ibckeeper.Keeper //TransferKeeper ibctransferkeeper.Keeper EvidenceKeeper evidencekeeper.Keeper GroupKeeper groupkeeper.Keeper AuthzKeeper authzkeeper.Keeper ConsensusParamsKeeper consensusparamkeeper.Keeper // evm keepers EvmKeeper *evmkeeper.Keeper FeeMarketKeeper feemarketkeeper.Keeper // zetachain keepers AuthorityKeeper authoritykeeper.Keeper LightclientKeeper lightclientkeeper.Keeper CrosschainKeeper crosschainkeeper.Keeper //IBCCrosschainKeeper ibccrosschainkeeper.Keeper ObserverKeeper *observerkeeper.Keeper FungibleKeeper fungiblekeeper.Keeper EmissionsKeeper emissionskeeper.Keeper // contains filtered or unexported fields }
App extends an ABCI application, but with most of its parameters exported. They are exported for convenience in creating helper functions, as object capabilities aren't needed for testing.
func New ¶
func New( logger log.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool, skipUpgradeHeights map[int64]bool, homePath string, invCheckPeriod uint, encodingConfig ethermint.EncodingConfig, appOpts servertypes.AppOptions, baseAppOptions ...func(*baseapp.BaseApp), ) *App
New returns a reference to an initialized ZetaApp.
func (*App) AppCodec ¶
AppCodec returns Zeta app codec.
NOTE: This is solely to be used for testing purposes as it may be desirable for modules to register their own custom testing types.
func (*App) AutoCliOpts ¶
func (app *App) AutoCliOpts() autocli.AppOptions
AutoCliOpts returns the autocli options for the app.
func (*App) BasicManager ¶
func (app *App) BasicManager() module.BasicManager
func (*App) BeginBlocker ¶
BeginBlocker application updates every begin block
func (*App) BlockedAddrs ¶
func (*App) EndBlocker ¶
EndBlocker application updates every end block
func (*App) ExportAppStateAndValidators ¶
func (app *App) ExportAppStateAndValidators( forZeroHeight bool, jailAllowedAddrs []string, modulesToExport []string, ) (servertypes.ExportedApp, error)
ExportAppStateAndValidators exports the state of the application for a genesis file.
func (*App) GetKey ¶
func (app *App) GetKey(storeKey string) *storetypes.KVStoreKey
GetKey returns the KVStoreKey for the provided store key.
NOTE: This is solely to be used for testing purposes.
func (*App) GetMemKey ¶
func (app *App) GetMemKey(storeKey string) *storetypes.MemoryStoreKey
GetMemKey returns the MemStoreKey for the provided mem key.
NOTE: This is solely used for testing purposes.
func (*App) GetSubspace ¶
func (app *App) GetSubspace(moduleName string) paramstypes.Subspace
GetSubspace returns a param subspace for a given module name.
NOTE: This is solely to be used for testing purposes.
func (*App) GetTKey ¶
func (app *App) GetTKey(storeKey string) *storetypes.TransientStoreKey
GetTKey returns the TransientStoreKey for the provided store key.
NOTE: This is solely to be used for testing purposes.
func (*App) InitChainer ¶
func (app *App) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error)
InitChainer application update at chain initialization
func (*App) InterfaceRegistry ¶
func (app *App) InterfaceRegistry() types.InterfaceRegistry
InterfaceRegistry returns Gaia's InterfaceRegistry
func (*App) LegacyAmino ¶
func (app *App) LegacyAmino() *codec.LegacyAmino
LegacyAmino returns app's amino codec.
NOTE: This is solely to be used for testing purposes as it may be desirable for modules to register their own custom testing types.
func (*App) LoadHeight ¶
LoadHeight loads a particular height
func (*App) ModuleAccountAddrs ¶
ModuleAccountAddrs returns all the app's module account addresses.
func (*App) ModuleManager ¶
func (*App) PreBlocker ¶
func (app *App) PreBlocker(ctx sdk.Context, _ *abci.RequestFinalizeBlock) (*sdk.ResponsePreBlock, error)
PreBlocker updates every pre begin block
func (*App) RegisterAPIRoutes ¶
RegisterAPIRoutes registers all application module routes with the provided API server.
func (*App) RegisterNodeService ¶
func (*App) RegisterTendermintService ¶
RegisterTendermintService implements the Application.RegisterTendermintService method.
func (*App) RegisterTxService ¶
RegisterTxService implements the Application.RegisterTxService method.
func (*App) SimulationManager ¶
func (app *App) SimulationManager() *module.SimulationManager
SimulationManager implements the SimulationApp interface
type GenesisState ¶
type GenesisState map[string]json.RawMessage