feat(rustproxy-http): add HTTP/2 auto-detection via ALPN with TTL-backed protocol cache and h1-only/h2 ALPN client configs
This commit is contained in:
@@ -195,7 +195,10 @@ pub async fn start_tls_http_backend(
|
||||
) -> JoinHandle<()> {
|
||||
use std::sync::Arc;
|
||||
|
||||
let acceptor = rustproxy_passthrough::build_tls_acceptor(cert_pem, key_pem)
|
||||
// Use h1-only acceptor: test backends speak raw HTTP/1.1 text,
|
||||
// so they must NOT advertise h2 via ALPN (which would cause
|
||||
// auto-detect to attempt h2 binary framing and fail).
|
||||
let acceptor = rustproxy_passthrough::build_tls_acceptor_h1_only(cert_pem, key_pem)
|
||||
.expect("Failed to build TLS acceptor");
|
||||
let acceptor = Arc::new(acceptor);
|
||||
let name = backend_name.to_string();
|
||||
|
||||
Reference in New Issue
Block a user