This is a new reconfiguration command which behaves like full-reconfigure
but only for a single tenant. This can be useful after connection issues
with code hosting systems, or potentially with Zuul cache bugs.
Because this is the first command-socket command with an argument, some
command-socket infrastructure changes are necessary. Additionally, this
includes some minor changes to make the services more consistent around
socket commands.
Change-Id: Ib695ab8e7ae54790a0a0e4ac04fdad96d60ee0c9
The command socket class currently deletes the command socket after
joining its worker thread. Make this more safe by moving the deletion
at the end of the worker thread.
Change-Id: I5170cad933f465cd7ba0485d2add8699c20c6679
This helps to avoid leaking domain sockets on the filesystem.
Change-Id: I767d66d1cee5e89e2f3c63158bc0cabfa2dd807e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
After sending the stop signal to the command socket it should be
closed explicitly. Otherwise a resource warning [1] is emitted to
stderr.
[1]: Resource warning:
(...)/zuul/executor/server.py:644: ResourceWarning: unclosed <socket.socket fd=24, family=AddressFamily.AF_UNIX, type=SocketKind.SOCK_STREAM, proto=0, raddr=(...)/executor.socket>
self.command_socket.stop()
Change-Id: I0e85ea9f5021e329abf825afbd8e29d134c08669
It exists only for py2/py3 compat. We do not need it any more.
This will explicitly break Zuul v3 for python2, which is different than
simply ceasing to test it and no longer declaring we support it. Since
we're not testing it any longer, it's bound to degrade overtime without
us noticing, so hopefully a clean and explicit break will prevent people
from running under python2 and it working for a minute, then breaking
later.
Change-Id: Ia16bb399a2869ab37a183f3f2197275bb3acafee
Signals and multiprocessing don't mix well. Instead of using
signals for things like stop and reconfiguration, use a socket
that accepts simple commands, and use the zuul-launcher
command to send them.
This implements reconfiguration and stopping. Other commands
(eg, graceful stop, pause, etc) can be implemented later.
Change-Id: I14b1fdc5e3a20f4b1161dbc14705ad424ad13fbd