|
|
@@ -172,6 +172,11 @@ pub struct EthereumConfig {
|
|
|
#[serde(default)]
|
|
|
pub fee: u128,
|
|
|
|
|
|
+ /// Only set the provider's fee when the provider is registered for the first time. Default is true.
|
|
|
+ /// This is useful to avoid resetting the fees on service restarts.
|
|
|
+ #[serde(default = "default_sync_fee_only_on_register")]
|
|
|
+ pub sync_fee_only_on_register: bool,
|
|
|
+
|
|
|
/// Historical commitments made by the provider.
|
|
|
pub commitments: Option<Vec<Commitment>>,
|
|
|
|
|
|
@@ -186,6 +191,10 @@ pub struct EthereumConfig {
|
|
|
pub block_delays: Vec<u64>,
|
|
|
}
|
|
|
|
|
|
+fn default_sync_fee_only_on_register() -> bool {
|
|
|
+ true
|
|
|
+}
|
|
|
+
|
|
|
fn default_block_delays() -> Vec<u64> {
|
|
|
vec![5]
|
|
|
}
|