|
| 1 | +<div align="center"> |
| 2 | + <a href="https://flare.network/" target="blank"> |
| 3 | + <img src="https://content.flare.network/Flare-2.svg" width="300" alt="Flare Logo" /> |
| 4 | + </a> |
| 5 | + <br /> |
| 6 | + <a href="CONTRIBUTING.md">Contributing</a> |
| 7 | + · |
| 8 | + <a href="SECURITY.md">Security</a> |
| 9 | + · |
| 10 | + <a href="CHANGELOG.md">Changelog</a> |
| 11 | +</div> |
| 12 | + |
1 | 13 | # Flare Systems Protocol Client |
2 | 14 |
|
3 | 15 | ... |
4 | 16 |
|
| 17 | +[](https://pkg.go.dev/github.com/flare-foundation/flare-system-client?tab=doc) |
| 18 | + |
5 | 19 | ## Configuration |
6 | 20 |
|
7 | 21 | The configuration is read from `toml` file. Some configuration |
@@ -123,38 +137,53 @@ gas_limit = 0 # (optional) gas limit for transaction. D |
123 | 137 | gas_price_multiplier = 0 # (optional for type 0 tx) sets the gas price to be a multiplier of the estimated gas price. Defaults to 0, which will simply use the estimate, OR a fixed gas price if gas_price_fixed is set (!= 0). |
124 | 138 | gas_price_fixed = 0 # (optional for type 0 tx) sets a fixed gas price for the transaction. Defaults to 0, which will use an estimate OR a multiplier of the estimate if gas_price_multiplier is set (!= 0). |
125 | 139 | # type 2 settings |
126 | | -max_priority_fee_per_gas = "20000000000" # (optional for type 2 tx) sets priority fee per gas for a transaction in wei. Defaults to 20GWei. |
127 | | -base_fee_per_gas_cap = 0 # (optional for type 2 tx) sets base fee per gas cap. Defaults to 3 times estimation of needed base fee to be included in the block. !!! It is strongly recommended to keep it default. Any fixed amount may prevent the transaction from being accepted !!! |
| 140 | +max_priority_fee_multiplier = 2 # (optional for type 2 tx) sets the max priority fee per gas to be a multiple of the estimated base fee. Defaults to 2. |
| 141 | +maximal_max_priority_fee_per_gas = 5000_000_000_000 # (optional for type 2 tx) maximal max priority fee per gas. Defaults to 5000 Gwei. |
| 142 | +minimal_max_priority_fee =100_000_000_000 # (optional for type 2 tx) minimal max priority fee per gas. Defaults to 100 Gwei. |
| 143 | +base_fee_multiplier = 4 # (optional for type 2 tx) sets the base fee to be a multiple of the estimated base fee. Defaults to 4. |
128 | 144 |
|
129 | | -[gas_relay] # applies to finalization transaction |
130 | | -tx_type = 0 |
131 | | -gas_limit = 0 |
132 | | -gas_price_multiplier = 0 |
133 | | -gas_price_fixed = 0 |
134 | | -max_priority_fee_per_gas = "20000000000" |
135 | | -base_fee_per_gas_cap = 0 |
136 | | -``` |
137 | 145 |
|
138 | | -Currently only type 0 transactions are supported for registration. |
139 | 146 |
|
140 | | -```toml |
141 | | -[gas_register] # applies to all voter registration transaction |
142 | | -tx_type = 0 |
143 | | -gas_limit = 0 |
144 | | -gas_price_multiplier = 0 |
145 | | -gas_price_fixed = 0 |
| 147 | +[gas_relay] # applies to finalization transaction |
| 148 | +tx_type = 2 |
| 149 | +max_priority_fee_multiplier = 2 |
| 150 | +maximal_max_priority_fee = 5000_000_000_000 # 5000 Gwei |
| 151 | +minimal_max_priority_fee = 100_000_000_000 # 100 Gwei |
| 152 | +base_fee_multiplier = 4 |
146 | 153 |
|
147 | 154 |
|
| 155 | +[gas_register] # applies to all voter registration transaction |
| 156 | +tx_type = 2 |
| 157 | +max_priority_fee_multiplier = 2 |
| 158 | +maximal_max_priority_fee = 5000_000_000_000 # 5000 Gwei |
| 159 | +minimal_max_priority_fee = 100_000_000_000 # 100 Gwei |
| 160 | +base_fee_multiplier = 4 |
| 161 | + |
| 162 | + |
| 163 | +[gas_systems_manager] # applies to transactions to FlareSystemsManager contract |
| 164 | +tx_type = 2 |
| 165 | +max_priority_fee_multiplier = 2 |
| 166 | +maximal_max_priority_fee = 5000_000_000_000 # 5000 Gwei |
| 167 | +minimal_max_priority_fee = 100_000_000_000 # 100 Gwei |
| 168 | +base_fee_multiplier = 4 |
| 169 | +``` |
148 | 170 |
|
| 171 | +```toml |
149 | 172 | [rewards] # reward signing configuration - clients.enabled_reward_signing must be set to true |
150 | 173 | # URL prefix for retrieving reward distribution data. |
| 174 | + |
151 | 175 | # A full URL will be constructed by appending the epoch id and expected file name: <prefix>/<epochId>/reward-distribution-data.json |
| 176 | + |
152 | 177 | # |
| 178 | + |
153 | 179 | # For example, if reward data for an epoch can be retrieved at https://raw.githubusercontent.com/flare-foundation/fsp-rewards/refs/heads/main/songbird/240/reward-distribution-data.json, |
| 180 | + |
154 | 181 | # then the url_prefix should be set to "https://raw.githubusercontent.com/flare-foundation/fsp-rewards/refs/heads/main/songbird" |
| 182 | + |
155 | 183 | url_prefix = "" |
156 | 184 | min_reward = 0 # minimum acceptable claim amount in wei for the identity address of this provider, default 0. |
157 | 185 | max_reward = 0 # (optional) maximum acceptable claim amount in wei for the identity address of this provider. If 0 or not set, no maximum is enforced. |
158 | | -retries = 8 # (optional) number of retries for fetching and signing reward data, default: 8. |
| 186 | +retries = 8 # (optional) number of retries for fetching and signing reward data, default: 8. |
159 | 187 | retry_interval = "6h" # (optional) interval between retries, default: 6 hours. |
| 188 | + |
160 | 189 | ``` |
0 commit comments