The daemon no longer receives the client descriptor handed over by the
frontend: nginx opens an ordinary http connection to it on one of the unix
sockets of the pool. Neither the php ancillary extension, nor
mod_proxy_fdpass2 for apache, nor ngx_http_fdpass_module for nginx, nor kTLS
are needed any more: the debian nginx package is enough. In exchange nginx
stays in the middle for the whole life of the connection, which in a comet
application is long.
The historic mode is one INSTALL.sh -D FALSE away.
The sample configuration was added under system/nginx/, and WARNING.txt was
rewritten: it only documented the old apache setup.
Two log traces had to be fixed before the direct mode could be used, because
they fired once per request instead of occasionally:
- "User associated with ID: N not found" was printed for every socket with
no user attached, that is for the head of every request. The message now
comes out only if the socket is in none of the known lists.
- "PP_REM" traced the removal of a pending page, which now happens on every
request: it moves under debug > 1.
Checked in the debian 13 container with the packaged nginx 1.26.3 (no added
module): static pages, the .htaccess protections rewritten in the
configuration, the login of five certified users, comet streaming, POST, and
three complete five player games over https recorded on postgresql. The
daemon log for a whole hand went from thousands of lines to about forty.
Behaviour under load and the reuse of connections between nginx and the
daemon remain to be checked.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014M1jiEq9cHdE5SE5j6vFuE