Closed danopia closed 1 year ago
I'm not incredibly convinced about the amount of abstraction done here. Like, whenever Kubernetes decides to handle WebSocket port forwarding multiplexing, it might not fit into the limited paradigm I have here. But it describes current and near-future PodExec, PodAttach, and PortForward fine, and it should fit into PodLogs as well if there's every any demand for PodLogs over WebSocket (though I don't expect this to be the case).
One particular thing I don't like is the async ready()
function on tunnels. For WebSockets it stops accepting new streams, and ideally starts processing inbound messages. But for SPDY it doesn't have anything to do because SPDY streams are independent from each other and the user can make more whenever.. So the function sorta leaks WS vs SPDY paradigms.
Oh well let's go
My goal here is to describe Kubernetes tunneling in a generic way so that it is valid for both types of tunnel transport supported by Kubernetes (SPDY/3.1 and Websockets).
Unfortunately, the two transports are given different semantics by Kubernetes.
Related:
14
6
3