]> git.proxmox.com Git - proxmox-backup.git/commit - src/server/command_socket.rs
server: add CommandoSocket where multiple users can register commands
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 2 Nov 2020 09:12:56 +0000 (10:12 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 2 Nov 2020 18:32:22 +0000 (19:32 +0100)
commitf3df613cb7cf6270a5e8752fc5f54cf23cc8ea38
treeb59a42ca82fe5c8719f38f88cd9853effce19114
parent056ee785676de26840c6391c6709b9122ddb71e9
server: add CommandoSocket where multiple users can register commands

This is a preparatory step to replace the task control socket with it
and provide a "reopen log file" command for the rest server.

Kept it simple by disallowing to register new commands after the
socket gets spawned, this avoids the need for locking.

If we really need that we can always wrap it in a Arc<RWLock<..>> or
something like that, or even nicer, register at compile time.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/server/command_socket.rs