Performance as a tcp proxy server?

Hal Snyder hal@REDACTED
Tue Feb 6 01:22:41 CET 2001


David Gould <dg@REDACTED> writes:

...

> To avoid the site meltdowns, I am proposing to limit the number of
> Mysql connections by placing a proxy process between the webservers
> (Mysql clients) and the Mysql server. This proxy will multiplex
> multiple sql client sessions onto each sql server connection.
> 
> Bad ascii diagram ...
> 
>     Client ----\
>   Client ----\  \
> Client ------- Proxy <====> Mysql
>   Client ----/  /
>     Client ----/
> 
> When a client sends a query, it must be queued until it can be sent
> on to the server. When a query is sent to the server, there may be
> some delay before the response. We need to continue accepting and
> queueing client queries during this time. When a response comes from
> the server it must be sent back to the client that originated the
> query, and the next queue query must be sent to the server.

I can't answer the important questions about throughput and load
limits, as our app is low traffic. But, our pilot Erlang project, put
into production last summer, does something quite similar to your
diagram, except that we are not only proxying and queuing, but also
providing failover on redundant custom databases over WAN links. It
has been extremely reliable, allowing support staff to sleep through
near-weekly outages in any one of the remote servers.

Warning: The principal programmer on the project turned into an FP
zealot, and doesn't like C++, Java, or Perl any more.  ;-)



More information about the erlang-questions mailing list