zaphoyd/websocketpp — comment on commit a89cb776a13113c5fa585b284bf26e8af51ed264
File:  line 0
By zaphoyd:

In the client case, connect() is called by end user code and the expectation is that a new connection will be created or it will fail. Failing here is an error condition that the client application needs to be able to deal with (and should probably not arise unless the client does incorrect things like stop the endpoint and then try and make a connection).

In the server case start_accept() is called in response to a remote client connection and the expectation is that the connection will be serviced or refused. Failing here is an expected condition that that is not the result of the server application doing something wrong. Dropping connections in low resource conditions or while stopping is normal server behavior.

What is missing is a log line on the server that notes when it refuses a connection for this reason so that the dropped connections can be debugged later. I will add that.