Documentation ¶
Index ¶
Constants ¶
View Source
const ( FlagContractQueryGasLimit = "contract-query-gas-limit" FlagCacheSize = "lru-size" )
config flags for wasm module
Variables ¶
This section is empty.
Functions ¶
func WriteConfigFile ¶
WriteConfigFile renders config using the template and writes it to configFilePath.
Types ¶
type BaseConfig ¶
type BaseConfig struct { // The maximum gas amount can be spent for contract query // The external query will invoke contract vm on wasm module, // so we need to restrict the max usage to prevent DoS attack ContractQueryGasLimit uint64 `mapstructure:"contract-query-gas-limit"` // Storing instances in the LRU will have no effect on // the results (still deterministic), but should lower // execution time at the cost of increased memory usage. // We cannot pick universal parameters for this, so // we should allow node operators to set it. CacheSize uint64 `mapstructure:"lru-size"` }
BaseConfig is the extra config required for wasm
type Config ¶
type Config struct {
BaseConfig `mapstructure:",squash"`
}
Config defines the server's top level configuration
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns the default settings for WasmConfig
func ParseConfig ¶
ParseConfig retrieves the default environment configuration for the application.
Click to show internal directories.
Click to hide internal directories.