[zmq] Don't take a new port when restart server
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
oslo.messaging |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
Currently restarting the service we bind to a new random port each time, so already connected clients have no ability to reconnect to the service by means of KEEP_ALIVE connection.
Purpose: Zmq driver should not manage such kind of reconnects, it should be done by means of underlying ZeroMQ layers.
Possible solution:
When service starts and if it has server-id in the target <Target ... server="server1">:
- check out this id in redis. (record presence in redis means repetitive runs, otherwise we run for the first time)
- If the id presents, don't bind to a new random port but
- get the port from redis record.
- In case the port was not closed or it is hold by another process
- bind to a random port as usual.
This solution would work if we don't have conflicting server names inside the same host.
tags: | added: zmq |
Changed in oslo.messaging: | |
status: | New → Won't Fix |