haproxy public development tree
Go to file
Willy Tarreau 4087346dab BUG/MAJOR: mux-h2: do not add a stream twice to the send list
In this long thread, Maciej Zdeb reported that the H2 mux was still
going through endless loops from time to time :

  https://www.mail-archive.com/haproxy@formilux.org/msg33709.html

What happens is the following :
- in h2s_frt_make_resp_data() we can set H2_SF_BLK_SFCTL and remove the
  stream from the send_list
- then in h2_shutr() and h2_shutw(), we check if the list is empty before
  subscribing the element, which is true after the case above
- then in h2c_update_all_ws() we still have H2_SF_BLK_SFCTL with the item
  in the send_list, thus LIST_ADDQ() adds it a second time.

This patch adds a check of list emptiness before performing the LIST_ADDQ()
when the flow control window opens. Maciej reported that it reliably fixed
the problem for him.

As later discussed with Olivier, this fixes the consequence of the issue
rather than its cause. The root cause is that a stream should never be in
the send_list with a blocking flag set and the various places that can lead
to this situation must be revisited. Thus another fix is expected soon for
this issue, which will require some observation. In the mean time this one
is easy enough to validate and to backport.

Many thanks to Maciej for testing several versions of the patch, each
time providing detailed traces which allowed to nail the problem down.

This patch must be backported to 1.9.
2019-05-13 08:15:10 +02:00
.github/ISSUE_TEMPLATE
contrib MINOR: systemd: support /etc/sysconfig/ for redhat based distrib 2019-05-07 14:11:55 +02:00
doc MINOR: streams: Introduce a new retry-on keyword, all-retryable-errors. 2019-05-10 18:05:35 +02:00
ebtree
examples CLEANUP: wurfl: removed deprecated methods 2019-04-23 11:00:23 +02:00
include BUILD: threads: fix again the __ha_cas_dw() definition 2019-05-11 18:13:29 +02:00
reg-tests REGTEST: Wrong assumption in IP:port logging test. 2019-05-07 13:58:35 +02:00
scripts BUILD: add BoringSSL to travis-ci build matrix 2019-05-10 10:39:29 +02:00
src BUG/MAJOR: mux-h2: do not add a stream twice to the send list 2019-05-13 08:15:10 +02:00
tests
.gitignore
.travis.yml BUILD: travis-ci: make TMPDIR global variable in travis-ci 2019-05-11 06:07:47 +02:00
CHANGELOG [RELEASE] Released version 2.0-dev2 2019-03-26 05:40:51 +01:00
CONTRIBUTING
INSTALL Revert "CLEANUP: wurfl: remove dead, broken and unmaintained code" 2019-04-23 10:34:43 +02:00
LICENSE
MAINTAINERS DOC: wurfl: added point of contact in MAINTAINERS file 2019-04-23 11:00:23 +02:00
Makefile REGTEST: replace LEVEL option by a more human readable one. 2019-04-23 15:14:52 +02:00
README
ROADMAP
SUBVERS
VERDATE [RELEASE] Released version 2.0-dev2 2019-03-26 05:40:51 +01:00
VERSION [RELEASE] Released version 2.0-dev2 2019-03-26 05:40:51 +01:00

The HAProxy documentation has been split into a number of different files for
ease of use.

Please refer to the following files depending on what you're looking for :

  - INSTALL for instructions on how to build and install HAProxy
  - LICENSE for the project's license
  - CONTRIBUTING for the process to follow to submit contributions

The more detailed documentation is located into the doc/ directory :

  - doc/intro.txt for a quick introduction on HAProxy
  - doc/configuration.txt for the configuration's reference manual
  - doc/lua.txt for the Lua's reference manual
  - doc/SPOE.txt for how to use the SPOE engine
  - doc/network-namespaces.txt for how to use network namespaces under Linux
  - doc/management.txt for the management guide
  - doc/regression-testing.txt for how to use the regression testing suite
  - doc/peers.txt for the peers protocol reference
  - doc/coding-style.txt for how to adopt HAProxy's coding style
  - doc/internals for developer-specific documentation (not all up to date)