fetch: improve the fetch protocol
Logging the stages of the fetch protocol is added to get some insight
of how far a fetch gets, while also providing some simple timings
using Instant::elapsed.
This allowed me to run a local client version of this fetch protocol and see what was happening. The 9s timeout was hit for the channel methods. So this was increased to 30s.
From there, I was able to see that a rad clone of an offending
repository was actually “finishing” but the final error would say that
the other side had disconnected. This lead to the realisation that the
call to done can be a fire and forget – log the error and continue
on with validation and refdb updates. I was then able to confirm that
the clone of the offending repository was able to be performed.
8 files changed
+83
-25
87d1cb50
→
b1435629
modified radicle-fetch/src/lib.rs
@@ -9,12 +9,15 @@ mod refs;
|
|
|
|
|
|
| + | |
|
|
|
|
| + | |
|
|
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -55,21 +58,27 @@ pub fn pull<S>(
|
|
|
|
|
|
| + | |
|
|
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| + | |
|
|
|
|
|
|
|
|
| - | |
| + | |
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -84,15 +93,31 @@ pub fn clone<S>(
|
|
|
|
|
|
| + | |
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| + | |
|
|
| - | |
| + | |
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
modified radicle-fetch/src/state.rs
@@ -1,4 +1,5 @@
|
|
| + | |
|
|
|
|
|
@@ -378,6 +379,7 @@ impl FetchState {
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -389,6 +391,7 @@ impl FetchState {
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -418,6 +421,12 @@ impl FetchState {
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -425,6 +434,22 @@ impl FetchState {
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -528,9 +553,12 @@ impl FetchState {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -541,12 +569,20 @@ impl FetchState {
|
|
|
|
|
|
| + | |
|
|
|
|
|
|
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified radicle-node/src/runtime.rs
@@ -4,7 +4,7 @@ pub mod thread;
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -262,7 +262,6 @@ impl Runtime {
|
|
|
|
|
|
| - | |
|
|
|
|
|
modified radicle-node/src/service.rs
@@ -1268,7 +1268,7 @@ where
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -1600,7 +1600,7 @@ where
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
modified radicle-node/src/service/io.rs
@@ -57,7 +57,7 @@ impl Outbox {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -101,7 +101,7 @@ impl Outbox {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
modified radicle-node/src/wire/protocol.rs
@@ -44,7 +44,7 @@ pub const NOISE_XK: HandshakePattern = HandshakePattern {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
modified radicle-node/src/worker.rs
@@ -29,8 +29,6 @@ pub use channels::{ChannelEvent, Channels};
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
modified radicle/src/node.rs
@@ -46,7 +46,7 @@ pub const DEFAULT_SOCKET_NAME: &str = "control.sock";
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|