rsocket-cpp icon indicating copy to clipboard operation
rsocket-cpp copied to clipboard

Pause accepting new connections but continue serving existing ones

Open phoad opened this issue 7 years ago • 0 comments

In one of the projects that will use RSocket, there are two functions to pause or stop the server, which is to be replaced by RSocketServer. (see: BaseThriftServer)

  • stop
  • stopListening

Stop is just calling rsocketServer->showdownAndWait().

But we miss the stopListening functionality which should only pause accepting new connections and continue serving the existing ones.

I wonder if we should have functionality to pause accepting new connections or creating new streams, i.e. if we have a higher level logic that checks the load and tries to save the server from getting overloaded.

phoad avatar Aug 10 '17 18:08 phoad