Re: [RFC] unified port directive

From: Alex Rousskov <rousskov_at_measurement-factory.com>
Date: Mon, 09 Jun 2014 10:47:17 -0600

On 06/08/2014 11:07 PM, Amos Jeffries wrote:

> I propose that we combine the http_port and https_port directives into
> a single directive called "port" with the old names as aliases and an
> option to select between TCP and TLS transport protocol.

Just "port" is a bad name, IMO, because there are many other, non-HTTP
*_ports in squid.conf. Consider using "http_port" name for both SSL and
plain transports, with appropriate transport defaults (that may even
depend on the port value!).

Please also keep ftp_port for Native FTP proxying in mind. That FTP code
works well and will be posted for review as soon as I am done
renaming/reshuffling classes/code as agreed earlier on squid-dev.

Other than the name, I have no objections, provided the internal code
storing and working with different HTTP* ports is appropriately merged
(most of that has already been done though).

> The two directives already share almost all configuration options and
> processing logic inside Squid.

Agreed.

> This will allow us to:
> 1) de-duplicate a lot of code managing each set of ports as separate
> lists, and

The proposed change is not necessary to do that. A lot of http*_port
managing/using code has been merged already, and all of it can be merged
without configuration changes except the trivial top-level
parsing/dumping functions.

> 2) more easily add UDP (CoAP), SCTP, SOCKS, and potentially other
> protocols as the transport under HTTP in future.

Agreed regarding adding transport protocols under HTTP.

Cheers,

Alex.
Received on Mon Jun 09 2014 - 16:47:28 MDT

This archive was generated by hypermail 2.2.0 : Tue Jun 10 2014 - 12:00:11 MDT