You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: clients/README.md
+38-1
Original file line number
Diff line number
Diff line change
@@ -218,6 +218,43 @@ If the transaction submission fails giving a `tx_failed` in the `result_codes` o
218
218
due to the converted destination account not having trustlines set up for the redeemed asset.
219
219
The destination account is derived automatically from the account that called the extrinsic on-chain.
220
220
221
+
### Debugging with `tokio-console`
222
+
The vault is `tokio-console` ready, with the feature **_`allow-debugger`_**. _Remember to [set the rustflags](https://github.com/tokio-rs/console?tab=readme-ov-file#instrumenting-your-program)!_
223
+
```
224
+
RUSTFLAGS="--cfg tokio_unstable" cargo run --bin vault --features allow-debugger
If using the [testchain](../testchain) and vault's `standalone-metadata` feature, you can use the command:
229
+
```
230
+
tokio-console http://127.0.0.1:6669
231
+
```
232
+
This will display:
233
+
<imgwidth="1138"alt="Screenshot 2024-05-13 at 6 33 33 PM"src="https://github.com/pendulum-chain/spacewalk/assets/2826165/6681a16c-84c0-47f5-abc6-e4ba6a7dc032">
234
+
The multiple ` tokio::task clients/vault/src/system.rs ` tasks follows the tasks spawned consecutively, in [system.rs](https://github.com/pendulum-chain/spacewalk/blob/main/clients/vault/src/system.rs):
235
+
236
+
* The first 4 tasks are from `fn create_initial_tasks(...)` :
237
+
* VaultId Registration Listener
238
+
* Restart Timer
239
+
* Stellar Transaction Listener
240
+
* Parachain Block Listener
241
+
* Next 5 tasks from `fn create_issue_tasks(...)` :
242
+
* Issue Request Listener
243
+
* Issue Cancel Listener
244
+
* Issue Execute Listener
245
+
* Issue Executor
246
+
* Issue Cancel Scheduler
247
+
* Next 4 tasks from `fn create_replace_tasks(...)` :
248
+
* Request Replace Listener
249
+
* Accept Replace Listener
250
+
* Execute Replace Listener
251
+
* Replace Cancellation Scheduler
252
+
* Redeem Request Listener
253
+
* The last 2 tasks from `create_bridge_metrics_tasks(...)` :
254
+
* Bridge Metrics Listener
255
+
* Bridge Metrics Poller
256
+
257
+
221
258
## Notes on the implementation of subxt
222
259
223
260
This section is supposed to help when encountering issues with communication of vault client and parachain.
@@ -257,4 +294,4 @@ found [here](https://docs.rs/subxt-macro/latest/subxt_macro/#adding-derives-for-
257
294
When the compiler complains about mismatched types although the types seem to be the same, you might have to use type
258
295
substitutions.
259
296
This is done by adding the `#[subxt(substitute_type = "some type")]` attribute to the metadata module.
260
-
More documentation can be found [here](https://docs.rs/subxt-macro/latest/subxt_macro/#substituting-types).
297
+
More documentation can be found [here](https://docs.rs/subxt-macro/latest/subxt_macro/#substituting-types).
0 commit comments