This commit is contained in:
parent
a5c8d4f0c8
commit
2b0bdc3257
4 changed files with 127 additions and 9 deletions
|
|
@ -333,6 +333,18 @@ impl<C: TransportConnection> GenericReceiver<C> {
|
|||
break 'stream;
|
||||
}
|
||||
Err(_) => {
|
||||
if frames == 0 {
|
||||
tracing::warn!(
|
||||
timeout = ?policy.read_timeout,
|
||||
"MTP receive stream timed out before its first complete frame"
|
||||
);
|
||||
} else {
|
||||
tracing::debug!(
|
||||
frames,
|
||||
timeout = ?policy.read_timeout,
|
||||
"MTP receive stream idle timeout"
|
||||
);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -376,6 +388,9 @@ impl<C: TransportConnection> GenericReceiver<C> {
|
|||
)
|
||||
.await;
|
||||
if !matches!(&body_read, Ok(Ok(()))) {
|
||||
if matches!(&body_read, Ok(Err(CommunicationError::StreamClosed))) {
|
||||
break 'stream;
|
||||
}
|
||||
tracing::warn!(
|
||||
pipe_chunk_len = chunk_len,
|
||||
?body_read,
|
||||
|
|
|
|||
Loading…
Reference in a new issue