I have a quite big DataSnap server that will be running 24/7, it will substitute a currently running MIDAS (COM) server. Now I'm facing the problem of how to update that server without having to force disconnection of all connected clients.
With the current midas server (that, by the way, doesn't have a huge traffic to serve) I simply wait until there are no connections, then shut down the server application and substitute the exe file. If a new connection occurred while the server was "down", being it a COM object, it will be "pulled up" by the OS, giving no problems to the clients.
The new DataSnap architecture isn't anymore based on COM (great!), but this way I lose the opportunity to stop the server without causing new connections to fail.
I've thought that a sort of TCP "proxy" or "tunnel" could solve my problem, so I can simply put a new server exe somewhere and have that "proxy" redirect client connections to the new DS server. I've tried TIdMappedPortTCP, but it continuously hangs at random points of the server-client dialog.
Any ideas?
EDIT: I'm using DataSnap on pure TCP/IP transport for efficiency reasons, so http proxies are not suitable for my specific case.