Struct sc_cli::ImportParams
source · pub struct ImportParams {
pub pruning_params: PruningParams,
pub database_params: DatabaseParams,
pub wasm_method: WasmExecutionMethod,
pub wasmtime_instantiation_strategy: WasmtimeInstantiationStrategy,
pub wasm_runtime_overrides: Option<PathBuf>,
pub execution_strategies: ExecutionStrategiesParams,
pub trie_cache_size: usize,
/* private fields */
}
Expand description
Parameters for block import.
Fields§
§pruning_params: PruningParams
§database_params: DatabaseParams
§wasm_method: WasmExecutionMethod
Method for executing Wasm runtime code.
wasmtime_instantiation_strategy: WasmtimeInstantiationStrategy
The WASM instantiation method to use.
Only has an effect when wasm-execution
is set to compiled
.
The copy-on-write strategies are only supported on Linux. If the copy-on-write variant of a strategy is unsupported the executor will fall back to the non-CoW equivalent.
The fastest (and the default) strategy available is pooling-copy-on-write
.
The legacy-instance-reuse
strategy is deprecated and will
be removed in the future. It should only be used in case of
issues with the default instantiation strategy.
wasm_runtime_overrides: Option<PathBuf>
Specify the path where local WASM runtimes are stored.
These runtimes will override on-chain runtimes when the version matches.
execution_strategies: ExecutionStrategiesParams
§trie_cache_size: usize
Specify the state cache size.
Providing 0
will disable the cache.
Implementations§
source§impl ImportParams
impl ImportParams
sourcepub fn trie_cache_maximum_size(&self) -> Option<usize>
pub fn trie_cache_maximum_size(&self) -> Option<usize>
Specify the trie cache maximum size.
sourcepub fn wasm_method(&self) -> WasmExecutionMethod
pub fn wasm_method(&self) -> WasmExecutionMethod
Get the WASM execution method from the parameters
sourcepub fn wasm_runtime_overrides(&self) -> Option<PathBuf>
pub fn wasm_runtime_overrides(&self) -> Option<PathBuf>
Enable overriding on-chain WASM with locally-stored WASM by specifying the path where local WASM is stored.
sourcepub fn execution_strategies(
&self,
is_dev: bool,
is_validator: bool
) -> ExecutionStrategies
pub fn execution_strategies(
&self,
is_dev: bool,
is_validator: bool
) -> ExecutionStrategies
Get execution strategies for the parameters
Trait Implementations§
source§impl Args for ImportParams
impl Args for ImportParams
source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
source§impl Clone for ImportParams
impl Clone for ImportParams
source§fn clone(&self) -> ImportParams
fn clone(&self) -> ImportParams
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for ImportParams
impl Debug for ImportParams
source§impl FromArgMatches for ImportParams
impl FromArgMatches for ImportParams
source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches
) -> Result<Self, Error>
fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches
) -> Result<Self, Error>
source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches
) -> Result<(), Error>
fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches
) -> Result<(), Error>
ArgMatches
to self
.source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches
) -> Result<(), Error>
fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches
) -> Result<(), Error>
ArgMatches
to self
.Auto Trait Implementations§
impl RefUnwindSafe for ImportParams
impl Send for ImportParams
impl Sync for ImportParams
impl Unpin for ImportParams
impl UnwindSafe for ImportParams
Blanket Implementations§
source§impl<T> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read moresource§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read moresource§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read moresource§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read moresource§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T, Outer> IsWrappedBy<Outer> for Twhere
Outer: AsRef<T> + AsMut<T> + From<T>,
T: From<Outer>,
impl<T, Outer> IsWrappedBy<Outer> for Twhere
Outer: AsRef<T> + AsMut<T> + From<T>,
T: From<Outer>,
source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
T
. Read moresource§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
unchecked_from
.source§impl<T, S> UniqueSaturatedInto<T> for Swhere
T: Bounded,
S: TryInto<T>,
impl<T, S> UniqueSaturatedInto<T> for Swhere
T: Bounded,
S: TryInto<T>,
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
T
.