wip: h3-0.0.8
This commit is contained in:
parent
67e78041b4
commit
9e743b0dca
4 changed files with 36 additions and 14 deletions
|
|
@ -37,8 +37,11 @@ pub enum RpxyError {
|
|||
|
||||
// http/3 errors
|
||||
#[cfg(any(feature = "http3-quinn", feature = "http3-s2n"))]
|
||||
#[error("H3 error: {0}")]
|
||||
H3Error(#[from] h3::Error),
|
||||
#[error("h3 connection error: {0}")]
|
||||
H3ConnectionError(#[from] h3::error::ConnectionError),
|
||||
#[cfg(any(feature = "http3-quinn", feature = "http3-s2n"))]
|
||||
#[error("h3 connection error: {0}")]
|
||||
H3StreamError(#[from] h3::error::StreamError),
|
||||
// #[cfg(feature = "http3-s2n")]
|
||||
// #[error("H3 error: {0}")]
|
||||
// H3Error(#[from] s2n_quic_h3::h3::Error),
|
||||
|
|
|
|||
|
|
@ -49,12 +49,17 @@ where
|
|||
}
|
||||
Err(e) => {
|
||||
warn!("HTTP/3 error on accept incoming connection: {}", e);
|
||||
match e.get_error_level() {
|
||||
h3::error::ErrorLevel::ConnectionError => break,
|
||||
h3::error::ErrorLevel::StreamError => continue,
|
||||
}
|
||||
break;
|
||||
}
|
||||
Ok(Some((req, stream))) => {
|
||||
// Ok(Some((req, stream))) => {
|
||||
Ok(Some(req_resolver)) => {
|
||||
let (req, stream) = match req_resolver.resolve_request().await {
|
||||
Ok((req, stream)) => (req, stream),
|
||||
Err(e) => {
|
||||
warn!("HTTP/3 error on resolve request in stream: {}", e);
|
||||
continue;
|
||||
}
|
||||
};
|
||||
// We consider the connection count separately from the stream count.
|
||||
// Max clients for h1/h2 = max 'stream' for h3.
|
||||
let request_count = self.globals.request_count.clone();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue