]> git.kaiwu.me - haproxy.git/commit
MEDIUM: haterm: Add support for 0-copy data forwading and option to disable it
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 2 Apr 2026 19:44:05 +0000 (21:44 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 3 Apr 2026 08:46:15 +0000 (10:46 +0200)
commitecf36f2ca897aacdbc6f03f89387198164ba1750
treee7549551961de30454b337540b75b4e82697d1a8
parent2a1afcf39d3fd7babd4fc8eab77391e2ee9ea33c
MEDIUM: haterm: Add support for 0-copy data forwading and option to disable it

The support for the zero-copy data forwarding was added and enabled by
default. The command line option '-dZ' was also added to disable the
feature.

Concretely, when haterm pushes the response payload, if the zero-copy
forwarding is supported, a dedicated function is used to do so.
hstream_ff_snd() will rely on se_nego_ff() to know how many data can send
and at the end, on se_done_ff() to really send data.

hstream_add_ff_data() function was added to perform the raw copy of the
payload in the sedesc I/O buffer.
src/haterm.c
src/haterm_init.c