I've been looking over at the proxy server example from Netty website:
The example source code handler has a volatile variable
private volatile Channel outboundChannel;
which takes care of the channel that connects to another server for proxy.
This got me to wonder if this is the correct and safe way to implement for multiple connections for proxy.
I would like to allow multiple connections(inbound) to connect to different outbounds, while making sure that every inbound connection is uniquely linked to the outbound channel.
According to my knowledge, Netty generates a new pipeline for each connection. Does this mean a newly generated handler by pipeline factory is uniquely dedicated to the new connection(channel)?
p.s. If I have 1,000 active connections to my Netty server, does this mean there are 1,000 different pipelines?