]> git.kaiwu.me - haproxy.git/commit
MINOR: init: also set the worker-id in file-less mode
authorWilly Tarreau <w@1wt.eu>
Fri, 25 Sep 2026 08:17:21 +0000 (10:17 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 25 Sep 2026 14:24:48 +0000 (16:24 +0200)
commit0ceb8c65fc28b8db060a6a3f96cfc127a3a4b2f6
tree81a93a3f49dc26f5b7f174317b3a799bf48d5279
parente06fd5f8a8ad44a776c3dea9e8111bab1e2e693a
MINOR: init: also set the worker-id in file-less mode

The worker-id generation at boot, as done in commit 3639aac31f ("MINOR:
config: add a "worker-id" global keyword to identify the worker"), would
escape the file-less mode that is used with haterm and haload. There's
nothing dramatic in this, but it may end up being surprising with certain
corner-case configs that would want to exploit it (logging, header
contents etc), so better set it now for consistency between any worker
mode.

It was visible by running haterm:

    $ ./haterm -L :8000 -G "stats socket /tmp/sock1 level admin"

and issuing:

    $ socat - /tmp/sock1 <<< "show info"

which didn't show the Worker_id line before the fix. No backport is
needed.
src/haproxy.c