Commit 08b0b8a
authored
## Description
More improvements to our `transport` example to ease dogfooding:
* new `--logs` flag (for both provide and fetch) for simple file
logging:
- without further config, creates a directory
`./logs/transfer-{cmd}-{date}-{endpoint_id}` and saves logs with
`iroh=trace,transfer=trace` to a `logs` file in that directory.
- different log level can be set with RUST_LOG
- different path can be set with `--logs-path`
- qlog files are also written to that directory if the `qlog` feature is
enabled
* New `--mode ping` option for `fetch` command: instead of transferring
as much data as possible, this just keeps the connection open until the
`--duration` is expired (default: 10s). This gives much smaller log
files (both tracing and qlog) so easier to debug when looking for
connection changes only.
* Regular output now includes the time since start after each line.
Useful to interpret the "switched to direct" etc lines after the fact
(they didn't have any time indication so far)
* Better formatting for durations
* Better spans on accept side. Each connection gets an `id` now that
easily allows to grep for that connection through both iroh and quinn
logs
* Print path ids with the paths stats and changes. This allows to
correlate with the tracing logs now.
With both logs and qlog in a single dir it's now really straightforward
to share it eg with sendme.
## Breaking Changes
<!-- Optional, if there are any breaking changes document them,
including how to migrate older code. -->
## Notes & open questions
Should `--logs` include `iroh_quinn=trace` by default or not?
## Change checklist
<!-- Remove any that are not relevant. -->
- [ ] Self-review.
- [ ] Documentation updates following the [style
guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text),
if relevant.
- [ ] Tests if relevant.
- [ ] All breaking changes documented.
- [ ] List all breaking changes in the above "Breaking Changes" section.
- [ ] Open an issue or PR on any number0 repos that are affected by this
breaking change. Give guidance on how the updates should be handled or
do the actual updates themselves. The major ones are:
- [ ] [`quic-rpc`](https://github.com/n0-computer/quic-rpc)
- [ ] [`iroh-gossip`](https://github.com/n0-computer/iroh-gossip)
- [ ] [`iroh-blobs`](https://github.com/n0-computer/iroh-blobs)
- [ ] [`dumbpipe`](https://github.com/n0-computer/dumbpipe)
- [ ] [`sendme`](https://github.com/n0-computer/sendme)
1 parent aa14381 commit 08b0b8a
7 files changed
Lines changed: 241 additions & 82 deletions
File tree
- iroh-base
- src
- iroh
- examples
- src/socket/remote_map
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
49 | 51 | | |
50 | 52 | | |
51 | 53 | | |
| 54 | + | |
52 | 55 | | |
53 | 56 | | |
54 | 57 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
| 110 | + | |
110 | 111 | | |
111 | 112 | | |
112 | 113 | | |
| |||
0 commit comments