haproxy/contrib
Willy Tarreau 19bc201c9f MEDIUM: connection: remove the intermediary polling state from the connection
Historically we used to require that the connections held the desired
polling states for the data layer and the socket layer. Then with muxes
these were more or less merged into the transport layer, and now it
happens that with all transport layers having their own state, the
"transport layer state" as we have it in the connection (XPRT_RD_ENA,
XPRT_WR_ENA) is only an exact copy of the undelying file descriptor
state, but with a delay. All of this is causing some difficulties at
many places in the code because there are still some locations which
use the conn_want_* API to remain clean and only rely on connection,
and count on a later collection call to conn_cond_update_polling(),
while others need an immediate action and directly use the FD updates.

Since our updates are now much cheaper, most of them being only an
atomic test-and-set operation, and since our I/O callbacks are deferred,
there's no benefit anymore in trying to "cache" the transient state
change in the connection flags hoping to cancel them before they
become an FD event. Better make such calls transparent indirections
to the FD layer instead and get rid of the deferred operations which
needlessly complicate the logic inside.

This removes flags CO_FL_XPRT_{RD,WR}_ENA and CO_FL_WILL_UPDATE.
A number of functions related to polling updates were either greatly
simplified or removed.

Two places were using CO_FL_XPRT_WR_ENA as a hint to know if more data
were expected to be sent after a PROXY protocol or SOCKSv4 header. These
ones were simply replaced with a check on the subscription which is
where we ought to get the autoritative information from.

Now the __conn_xprt_want_* and their conn_xprt_want_* counterparts
are the same. conn_stop_polling() and conn_xprt_stop_both() are the
same as well. conn_cond_update_polling() only causes errors to stop
polling. It also becomes way more obvious that muxes should not at
all employ conn_xprt_{want|stop}_{recv,send}(), and that the call
to __conn_xprt_stop_recv() in case a mux failed to allocate a buffer
is inappropriate, it ought to unsubscribe from reads instead. All of
this definitely requires a serious cleanup.
2020-02-21 11:21:12 +01:00
..
51d/src BUILD/MINOR: 51d: Updated build registration output to indicate thatif the library is a dummy one or not. 2019-06-13 18:00:54 +02:00
base64
debug MEDIUM: connection: remove the intermediary polling state from the connection 2020-02-21 11:21:12 +01:00
deviceatlas BUILD: contrib/da: remove an "unused" warning 2019-11-15 13:39:16 +01:00
halog CLEANUP: fix a typo in a comment for the contrib/halog subsystem 2018-11-12 08:52:16 +01:00
hpack BUILD: use inttypes.h instead of stdint.h 2019-04-01 07:44:56 +02:00
ip6range
iprange CONTRIB: iprange: Fix compiler warning in iprange.c 2017-12-20 09:36:58 +01:00
mod_defender MAJOR: chunks: replace struct chunk with struct buffer 2018-07-19 16:23:43 +02:00
modsecurity MAJOR: http: Remove the HTTP legacy code 2019-07-19 09:24:12 +02:00
netsnmp-perl
plug_qdisc BUILD: use inttypes.h instead of stdint.h 2019-04-01 07:44:56 +02:00
prometheus-exporter MINOR: counters: Remove failed_secu counter and use denied_resp instead 2020-01-20 15:18:45 +01:00
selinux
spoa_example BUILD: use inttypes.h instead of stdint.h 2019-04-01 07:44:56 +02:00
spoa_server DOC: contrib: spoa_server Add some hints for building spoa_server 2019-07-05 16:31:50 +02:00
syntax-highlight MEDIUM: Make '(cli|con|srv)timeout' directive fatal 2019-06-17 13:35:54 +02:00
systemd MINOR: systemd: support /etc/sysconfig/ for redhat based distrib 2019-05-07 14:11:55 +02:00
tcploop
trace
wireshark-dissectors/peers BUILD: use inttypes.h instead of stdint.h 2019-04-01 07:44:56 +02:00
wurfl CONTRIB: wurfl: address 3 build issues in the wurfl dummy library 2019-05-22 14:59:08 +02:00