Boost logo

Boost Users :

From: Dominique Devienne (ddevienne_at_[hidden])
Date: 2020-04-21 11:59:22


Imagine I have a WebSocket server, implemented using Boost.Asio and
Boost.Beast.

It's deployed and serving clients in production or test environments, but I
fixed a bug, checked in a fix, passed CI, and would like to redeploy, but
w/o downtime for existing clients. New clients should use the same
address, but be served by the newly deployed fixed server. While
on-ongoing WebSocket connections keep on using the old server.

Is that possible? In-process? Or one must use some kind of "front-end
server" redirecting
new traffic (i.e. new WebSocket session and/or HTTP requests) to separate
processes?
(nginx? little GoLang exe? In C++ Boost.Asio based? else?)

If not possible in-process, then how to know when older server is no longer
in use, to gracefully stop it? Asio servers typically run forever, i.e.
never run out of work, even when they temporarily have nothing to do, by
design.

The goal is to do this on "premise" (i.e. not in the cloud), on a single
machine (no containers), and cross-platform (Windows and Linux).

Thanks, --DD



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net