On 11/25/2018 6:13 PM, Matthew Flatt wrote:
An alternative to exposing `SO_REUSEPORT` would be to allow TCP
listeners to be sent across place channels, so multiple places in same
Racket process could accept connections from the same listener. That
would only work for place-based parallelism, but it would be portable
and straightforward to implement --- and I'm happy to add it if anyone
would find that capability useful.

AFAIK, a single process can't open any listen port more than once - so exposing  SO_REUSEPORT  wouldn't necessarily help.  However, I seem to recall Jay McCarthy mentioning that TCP ports can be sent over place channels.  Since listen gives you a new port for each connection, it should be possible to have a centralized listener offloading processing to a place.

But this still isn't the same as with multiple processes.  A listen port has a fixed sized queue of waiting connections - it's adjustable within boundaries, but can't be exceeded by a single process.  With multiple processes, the queue is magnified by the number of processes - each process can queue that number of connections.  It's an important distinction if the connection load is very heavy.

George

--
You received this message because you are subscribed to the Google Groups "Racket 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to