TCP-packet processing in outbound proxy in linkerd-proxy #10145
-
Hello. I'm trying to understand how |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
In order to start understanding the proxy, understanding tower, one of the core libraries it uses, will be very helpful. If you read through those docs, you'll start to get a sense about how different layers and stacks compose to make any of the various "services" that you'll see in the proxy code. As for the outbound TCP-related code in the proxy, you'll want to start in If you're not familiar with Rust, I'd recommend working in an environment with the Rust language server so that you can click through to function definitions and get an idea about what types are being worked with. |
Beta Was this translation helpful? Give feedback.
In order to start understanding the proxy, understanding tower, one of the core libraries it uses, will be very helpful. If you read through those docs, you'll start to get a sense about how different layers and stacks compose to make any of the various "services" that you'll see in the proxy code.
As for the outbound TCP-related code in the proxy, you'll want to start in
linkerd/app/outbound/src/lib.rs
, specifically in fn mk_proxy. You can see how we start with creating thelogical
andforward
stacks, and then use those to create a single stack that handles things like discovery and instrumentation.If you're not familiar with Rust, I'd recommend working in an environment with the Rust l…