News for hackers. Stuff that matters.
Re:Curl HTTP/3 Performance by kiitos on Sunday January 28, 2024 @05:51PM (#39170683)
TCP connections are bottlenecked not just by the browser/client, but also at the load-balancer/server. Modulo SO_REUSEPORT, a server can maintain at most 64k active connections, which is far below any reasonable expectation for capacity of concurrent requests. You have to decouple application-level requests from physical-level connections to get any kind of reasonable performance out of a protocol. This has been pretty well understood for decades.
Re:Curl HTTP/3 Performance by otterley on Sunday January 28, 2024 @08:11PM (#39171708)
That limitation was overcome over 20 years ago with the invention of Direct Server Return (DSR) technology, since the remote IP becomes that of the actual client. (This also helped relieve pressure on load balancers since they don't need to process return traffic.) Another way to overcome this would be to use netblocks instead of IP addresses on both the load balancers (upstream side) and the server side (so the LB has multiple IPs to connect to and the server to respond from).

The benefit of DSR became mitigated a bit after CGNAT (in the IPv4 space anyway) began to be rolled out, since it can masquerade a large group of clients behind a single IP address. (CGNAT poses other, different problems related to fraud and abuse mitigation.)

Re:Curl HTTP/3 Performance by kiitos on Sunday January 28, 2024 @11:20PM (#39172644)
It's not a question of IP addresses, it's about connections.
Re:Curl HTTP/3 Performance by otterley on Monday January 29, 2024 @03:03AM (#39173899)
Which limit, exactly, are you referring to? Both load balancers and backend servers can juggle millions of concurrent connections nowadays. You mentioned a 64k connection limit but that’s not a hard file descriptor limit, nor does the 65536 port limit apply if the source and/or destination IPs differ.
Re:Curl HTTP/3 Performance by kiitos on Wednesday January 31, 2024 @12:20AM (#39200266)
> Both load balancers and backend servers can juggle millions of concurrent connections nowadays.

Maybe with SO_REUSEPORT, but not in general.

A TCP connection is identified by a 5-tuple that requires a unique port for both the client and server. TCP represents ports as uint16s, which means the max number of possible ports per address is 65536.

tl;dr: 1 server IP address = no more than 64k incoming connections

Re:Curl HTTP/3 Performance by otterley on Wednesday January 31, 2024 @01:36PM (#39207542)
Yes, I'm aware that 4-tuples must be unique. And so, by having a LB and/or server bind to more than one IP address, you can easily overcome that limit.
Re:Curl HTTP/3 Performance by kiitos on Wednesday January 31, 2024 @06:26PM (#39210938)
If you have multiple client-accessible IP addresses available to a server, I guess? But that's in no way common?
Re:Curl HTTP/3 Performance by otterley on Thursday February 01, 2024 @01:41PM (#39219534)
It's quite common in Kubernetes deployments, where each server in a separate Pod binds to a separate IP address.

And, as I said before, with DSR, there's a broad diversity of client IPs, so a single server address doesn't typically cause concerns with 4-tuple exhaustion.

Re:Curl HTTP/3 Performance by kiitos on Thursday February 01, 2024 @07:14PM (#39223355)
I think we're speaking from wildly different, and incompatible, contexts.

DSR is niche at best, not something that can be assumed.