From 7d88d02b36b191253766640a2158f4cab230034c Mon Sep 17 00:00:00 2001 From: Oliver Gould Date: Fri, 17 Dec 2021 18:25:44 +0000 Subject: [PATCH] inbound: Simplify GatewayIo type Since the legacy gateway mode has been removed from the proxy, we no longer need to support multiple I/O types for the gateway. This change drops the unused I/O variant from the GatewayIo type. --- linkerd/app/inbound/src/direct.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/linkerd/app/inbound/src/direct.rs b/linkerd/app/inbound/src/direct.rs index f55b11e5c9..4927ccbb20 100644 --- a/linkerd/app/inbound/src/direct.rs +++ b/linkerd/app/inbound/src/direct.rs @@ -50,7 +50,7 @@ pub struct ClientInfo { type TlsIo = tls::server::Io>, I>; type FwdIo = SensorIo>>; -pub type GatewayIo = io::EitherIo, SensorIo>>; +pub type GatewayIo = FwdIo; #[derive(Clone)] struct TlsParams { @@ -167,7 +167,6 @@ impl Inbound { // HTTP detection is not necessary in this case, since the transport // header indicates the connection's HTTP version. svc::stack(gateway.clone()) - .push_on_service(svc::MapTargetLayer::new(io::EitherIo::Left)) .push(transport::metrics::NewServer::layer( rt.metrics.proxy.transport.clone(), ))