]> git.ipfire.org Git - thirdparty/haproxy.git/log
thirdparty/haproxy.git
14 years ago[MEDIUM] IPv6 support for stick-tables
David du Colombier [Thu, 24 Mar 2011 10:09:31 +0000 (11:09 +0100)] 
[MEDIUM] IPv6 support for stick-tables

Since IPv6 is a different type than IPv4, the pattern fetch functions
src6 and dst6 were added. IPv6 stick-tables can also fetch IPv4 addresses
with src and dst. In this case, the IPv4 addresses are mapped to their
IPv6 counterpart, according to RFC 4291.

14 years ago[DOC] update ROADMAP file
Willy Tarreau [Mon, 28 Mar 2011 23:00:12 +0000 (01:00 +0200)] 
[DOC] update ROADMAP file

14 years ago[MINOR] acl: add support for table_cnt and table_avl matches
Willy Tarreau [Mon, 28 Mar 2011 22:57:02 +0000 (00:57 +0200)] 
[MINOR] acl: add support for table_cnt and table_avl matches

Those trivial matches respectively return the number of entries used
in a stick-table and the number of entries still available in a table.

14 years ago[BUG] stream_sock: fix handling for server side PROXY protocol
Willy Tarreau [Mon, 28 Mar 2011 21:17:54 +0000 (23:17 +0200)] 
[BUG] stream_sock: fix handling for server side PROXY protocol

Patch 5ab04ec47c9946a2bbc535687c023215ca813da0 was incomplete,
because if the first send() fails on an empty buffer, we fail
to rearm the polling and we can't establish the connection
anymore.

The issue was reported by Ben Timby who provided large amounts
of traces of various tests helping to reliably reproduce the issue.

14 years ago[DOC] document IPv6 support for syslog
David du Colombier [Thu, 17 Mar 2011 09:40:23 +0000 (10:40 +0100)] 
[DOC] document IPv6 support for syslog

14 years ago[MEDIUM] IPv6 support for syslog
David du Colombier [Thu, 24 Mar 2011 11:23:00 +0000 (12:23 +0100)] 
[MEDIUM] IPv6 support for syslog

14 years ago[OPTIM] buffers: uninline buffer_forward()
Willy Tarreau [Mon, 28 Mar 2011 14:25:58 +0000 (16:25 +0200)] 
[OPTIM] buffers: uninline buffer_forward()

Since the latest additions to buffer_forward(), it became too large for
inlining, so let's uninline it. The code size drops by 3kB. Should be
backported to 1.4 too.

14 years ago[BUG] http: fix content-length handling on 32-bit platforms
Willy Tarreau [Mon, 28 Mar 2011 14:06:28 +0000 (16:06 +0200)] 
[BUG] http: fix content-length handling on 32-bit platforms

Despite much care around handling the content-length as a 64-bit integer,
forwarding was broken on 32-bit platforms due to the 32-bit nature of
the ->to_forward member of the "buffer" struct. The issue is that this
member is declared as a long, so while it works OK on 64-bit platforms,
32-bit truncate the content-length to the lower 32-bits.

One solution could consist in turning to_forward to a long long, but it
is used a lot in the critical path, so it's not acceptable to perform
all buffer size computations on 64-bit there.

The fix consists in changing the to_forward member to a strict 32-bit
integer and ensure in buffer_forward() that only the amount of bytes
that can fit into it is considered. Callers of buffer_forward() are
responsible for checking that their data were taken into account. We
arbitrarily ensure we never consider more than 2G at once.

That's the way it was intended to work on 32-bit platforms except that
it did not.

This issue was tracked down hard at Exosec with Bertrand Jacquin,
Thierry Fournier and Julien Thomas. It remained undetected for a long
time because files larger than 4G are almost always transferred in
chunked-encoded format, and most platforms dealing with huge contents
these days run on 64-bit.

The bug affects all 1.5 and 1.4 versions, and must be backported.

14 years ago[MINOR] tools: add two macros MID_RANGE and MAX_RANGE
Willy Tarreau [Mon, 28 Mar 2011 13:55:43 +0000 (15:55 +0200)] 
[MINOR] tools: add two macros MID_RANGE and MAX_RANGE

Those will be used later, they return the largest and middle integer
possible for a given variable or type.

14 years ago[BUG] http: fix possible incorrect forwarded wrapping chunk size (take 2)
Willy Tarreau [Tue, 1 Mar 2011 19:04:36 +0000 (20:04 +0100)] 
[BUG] http: fix possible incorrect forwarded wrapping chunk size (take 2)

Fix acd20f80 was incomplete, the computed "bytes" value was not used.

This fix must be backported to 1.4.

14 years ago[BUG] log: retrieve the target from the session, not the SI
Willy Tarreau [Sun, 27 Mar 2011 17:53:06 +0000 (19:53 +0200)] 
[BUG] log: retrieve the target from the session, not the SI

Since we now have the copy of the target in the session, use it instead
of relying on the SI for it. The SI drops the target upon unregister()
so applets such as stats were logged as "NOSRV".

14 years ago[BUG] session: conn_retries was not always initialized
Willy Tarreau [Sun, 27 Mar 2011 17:16:56 +0000 (19:16 +0200)] 
[BUG] session: conn_retries was not always initialized

Johannes Smith reported some wrong retries count in logs associated with bad
requests. The cause was that the conn_retries field in the stream interface
was only initialized when attempting to connect, but is used when logging,
possibly with an uninitialized value holding last connection's conn_retries.
This could have been avoided by making use of a stream interface initializer.

This bug is 1.5-specific.

14 years ago[TESTS] provide a test case for various address formats
Willy Tarreau [Fri, 4 Mar 2011 14:46:16 +0000 (15:46 +0100)] 
[TESTS] provide a test case for various address formats

14 years ago[DOC] fix a minor typo
David du Colombier [Thu, 17 Mar 2011 09:40:22 +0000 (10:40 +0100)] 
[DOC] fix a minor typo

14 years ago[DOC] document IPv6 support for server
David du Colombier [Thu, 17 Mar 2011 09:40:26 +0000 (10:40 +0100)] 
[DOC] document IPv6 support for server

14 years ago[DOC] update IPv6 support for bind
David du Colombier [Thu, 17 Mar 2011 09:40:27 +0000 (10:40 +0100)] 
[DOC] update IPv6 support for bind

14 years ago[BUILD] add the USE_GETADDRINFO build option
Willy Tarreau [Wed, 23 Mar 2011 19:00:53 +0000 (20:00 +0100)] 
[BUILD] add the USE_GETADDRINFO build option

This one is used to call getaddrinfo() to resolve IPv6 host names.

14 years ago[MEDIUM] use getaddrinfo to resolve names if gethostbyname fail
David du Colombier [Thu, 17 Mar 2011 09:40:16 +0000 (10:40 +0100)] 
[MEDIUM] use getaddrinfo to resolve names if gethostbyname fail

Function gethostbyname is deprecated since IEEE Std 1003.1-2008 and
was replaced by getaddrinfo (available since IEEE Std 1003.1-2004).
Contrary to gethostbyname, getaddrinfo is specified to support both
IPv4 and IPv4 addresses.
Since some libc doesn't handle getaddrinfo properly, constant
USE_GETADDRINFO must be defined at compile time to enable use of
getaddrinfo.

14 years ago[MINOR] cfgparse: better report wrong listening addresses and make use of str2sa_range
Willy Tarreau [Fri, 4 Mar 2011 14:43:13 +0000 (15:43 +0100)] 
[MINOR] cfgparse: better report wrong listening addresses and make use of str2sa_range

It's always been a mess to debug wrong listening addresses because
the parsing function does not indicate the file and line number. Now
it does. Since the code was almost a duplicate of str2sa_range, it
now makes use of it and has been sensibly reduced.

14 years ago[MINOR] update comment about IPv6 support for server
David du Colombier [Thu, 17 Mar 2011 09:40:28 +0000 (10:40 +0100)] 
[MINOR] update comment about IPv6 support for server

14 years ago[MEDIUM] config: rework the IPv4/IPv6 address parser to support host-only addresses
Willy Tarreau [Fri, 4 Mar 2011 14:31:53 +0000 (15:31 +0100)] 
[MEDIUM] config: rework the IPv4/IPv6 address parser to support host-only addresses

The parser now distinguishes between pure addresses and address:port. This
is useful for some config items where only an address is required.

Raw IPv6 addresses are now parsed, but IPv6 host name resolution is still not
handled (gethostbyname does not resolve IPv6 names to addresses).

14 years ago[BUG] standard: is_addr return value for IPv4 was inverted
David du Colombier [Tue, 22 Mar 2011 10:39:41 +0000 (11:39 +0100)] 
[BUG] standard: is_addr return value for IPv4 was inverted

14 years ago[DOC] update ROADMAP file
Willy Tarreau [Tue, 22 Mar 2011 13:38:00 +0000 (14:38 +0100)] 
[DOC] update ROADMAP file

14 years ago[BUILD] proto_tcp: fix build issue with CTTPROXY
Willy Tarreau [Sun, 20 Mar 2011 13:03:54 +0000 (14:03 +0100)] 
[BUILD] proto_tcp: fix build issue with CTTPROXY

Recent sockaddr_storage changes broke the almost unused cttproxy code.
Fix is obvious.

14 years ago[DOC] update the spec on the proxy protocol
Willy Tarreau [Sun, 20 Mar 2011 10:32:40 +0000 (11:32 +0100)] 
[DOC] update the spec on the proxy protocol

We now support it on the server side too.

14 years ago[MEDIUM] server: add support for the "send-proxy" option
Willy Tarreau [Sun, 20 Mar 2011 09:32:26 +0000 (10:32 +0100)] 
[MEDIUM] server: add support for the "send-proxy" option

This option enables use of the PROXY protocol with the server, which
allows haproxy to transport original client's address across multiple
architecture layers.

14 years ago[MEDIUM] stream_sock: add support for sending the proxy protocol header line
Willy Tarreau [Sun, 20 Mar 2011 09:16:46 +0000 (10:16 +0100)] 
[MEDIUM] stream_sock: add support for sending the proxy protocol header line

Upon connection establishment, stream_sock is now able to send a PROXY
line before sending any data. Since it's possible that the buffer is
already full, and we don't want to allocate a block for that line, we
compute it on-the-fly when we need it. We just store the offset from
which to (re-)send from the end of the line, since it's assumed that
multiple outputs of the same proxy line will be strictly equivalent. In
practice, one call is enough. We just make sure to handle the case where
the first send() would indicate an incomplete output, eventhough it's
very unlikely to ever happen.

14 years ago[MINOR] frontend: add a make_proxy_line function
Willy Tarreau [Sun, 20 Mar 2011 09:15:22 +0000 (10:15 +0100)] 
[MINOR] frontend: add a make_proxy_line function

This function will build a PROXY protocol line header from two addresses
(IPv4 or IPv6). AF_UNIX family will be reported as UNKNOWN.

14 years ago[BUG] session: src_conn_cur was returning src_conn_cnt instead
Willy Tarreau [Wed, 16 Mar 2011 05:55:50 +0000 (06:55 +0100)] 
[BUG] session: src_conn_cur was returning src_conn_cnt instead

Issue reported by Cory Forsyth and diagnosed by Cyril Bonté.
Just a plain stupid copy-paste of the wrong fetch function call.

14 years ago[DOC] update ROADMAP file
Willy Tarreau [Wed, 16 Mar 2011 05:54:36 +0000 (06:54 +0100)] 
[DOC] update ROADMAP file

14 years ago[RELEASE] Released version 1.5-dev4
Willy Tarreau [Sun, 13 Mar 2011 21:15:02 +0000 (22:15 +0100)] 
[RELEASE] Released version 1.5-dev4

Released version 1.5-dev4 with the following main changes :
    - [MINOR] cfgparse: Check whether the path given for the stats socket actually fits into the sockaddr_un structure to avoid truncation.
    - [MINOR] unix sockets : inherits the backlog size from the listener
    - [CLEANUP] unix sockets : move create_uxst_socket() in uxst_bind_listener()
    - [DOC] fix a minor typo
    - [DOC] fix ignore-persist documentation
    - [MINOR] add warnings on features not compatible with multi-process mode
    - [BUG] http: fix http-pretend-keepalive and httpclose/tunnel mode
    - [MINOR] stats: add support for several packets in stats admin
    - [BUG] stats: admin commands must check the proxy state
    - [BUG] stats: admin web interface must check the proxy state
    - [MINOR] http: add pattern extraction method to stick on query string parameter
    - [MEDIUM] add internal support for IPv6 server addresses
    - [MINOR] acl: add be_id/srv_id to match backend's and server's id
    - [MINOR] log: add support for passing the forwarded hostname
    - [MINOR] log: ability to override the syslog tag
    - [MINOR] checks: add PostgreSQL health check
    - [DOC] update ROADMAP file
    - [BUILD] pattern: use 'int' instead of 'int32_t'
    - [OPTIM] linux: add support for bypassing libc to force using vsyscalls
    - [BUG] debug: report the correct poller list in verbose mode
    - [BUG] capture: do not capture a cookie if there is no memory left
    - [BUG] appsession: fix possible double free in case of out of memory
    - [CRITICAL] cookies: mixing cookies in indirect mode and appsession can crash the process
    - [BUG] http: correctly update the header list when removing two consecutive headers
    - [BUILD] add the CPU=native and ARCH=32/64 build options
    - [BUILD] add -fno-strict-aliasing to fix warnings with gcc >= 4.4
    - [CLEANUP] hash: move the avalanche hash code globally available
    - [MEDIUM] hash: add support for an 'avalanche' hash-type
    - [DOC] update roadmap file
    - [BUG] http: do not re-enable the PROXY analyser on keep-alive
    - [OPTIM] http: don't send each chunk in a separate packet
    - [DOC] fix minor typos reported recently in the peers section
    - [DOC] fix another typo in the doc
    - [MINOR] stats: report HTTP message state and buffer flags in error dumps
    - [BUG] http chunking: don't report a parsing error on connection errors
    - [BUG] stream_interface: truncate buffers when sending error messages
    - [MINOR] http: support wrapping messages in error captures
    - [MINOR] http: capture incorrectly chunked message bodies
    - [MINOR] stats: add global event ID and count
    - [BUG] http: analyser optimizations broke pipelining
    - [CLEANUP] frontend: only apply TCP-specific settings to TCP/TCP6 sockets
    - [BUG] http: fix incorrect error reporting during data transfers
    - [CRITICAL] session: correctly leave turn-around and queue states on abort
    - [BUG] session: release slot before processing pending connections
    - [MINOR] tcp: add support for dynamic MSS setting
    - [BUG] stick-table: correctly terminate string keys during lookups
    - [BUG] acl: fix handling of empty lines in pattern files
    - [BUG] stick-table: use the private buffer when padding strings
    - [BUG] ebtree: fix ebmb_lookup() with len smaller than the tree's keys
    - [OPTIM] ebtree: ebmb_lookup: reduce stack usage by moving the return code out of the loop
    - [OPTIM] ebtree: inline ebst_lookup_len and ebis_lookup_len
    - [REVERT] undo the stick-table string key lookup fixes
    - [MINOR] http: improve url_param pattern extraction to ignore empty values
    - [BUILD] frontend: shut a warning with TCP_MAXSEG
    - [BUG] http: update the header list's tail when removing the last header
    - [DOC] fix minor typo in the proxy protocol doc
    - [DOC] fix typos (http-request instead of http-check)
    - [BUG] http: use correct ACL pointer when evaluating authentication
    - [BUG] cfgparse: correctly count one socket per port in ranges
    - [BUG] startup: set the rlimits before binding ports, not after.
    - [BUG] acl: srv_id must return no match when the server is NULL
    - [MINOR] acl: add ability to check for internal response-only parameters
    - [MINOR] acl: srv_id is only valid in responses
    - [MINOR] config: warn if response-only conditions are used in "redirect" rules
    - [BUG] acl: fd leak when reading patterns from file
    - [DOC] fix minor typo in "usesrc"
    - [BUG] http: fix possible incorrect forwarded wrapping chunk size
    - [BUG] http: fix computation of message body length after forwarding has started
    - [BUG] http: balance url_param did not work with first parameters on POST
    - [TESTS] update the url_param regression test to test check_post too
    - [DOC] update ROADMAP
    - [DOC] internal: reflect the fact that SI_ST_ASS is transient
    - [BUG] config: don't crash on empty pattern files.
    - [MINOR] stream_interface: make use of an applet descriptor for IO handlers
    - [REORG] stream_interface: move the st0, st1 and private members to the applet
    - [REORG] stream_interface: split the struct members in 3 parts
    - [REORG] session: move client and server address to the stream interface
    - [REORG] tcp: make tcpv4_connect_server() take the target address from the SI
    - [MEDIUM] stream_interface: store the target pointer and type
    - [CLEANUP] stream_interface: remove the applet.handler pointer
    - [MEDIUM] log: take the logged server name from the stream interface
    - [CLEANUP] session: remove data_source from struct session
    - [CLEANUP] stats: make all dump functions only rely on the stream interface
    - [REORG] session: move the data_ctx struct to the stream interface's applet
    - [MINOR] proxy: add PR_O2_DISPATCH to detect dispatch mode
    - [MINOR] cfgparse: only keep one of dispatch, transparent, http_proxy
    - [MINOR] session: add a pointer to the new target into the session
    - [MEDIUM] session: remove s->prev_srv which is not needed anymore
    - [CLEANUP] stream_interface: use inline functions to manipulate targets
    - [MAJOR] session: remove the ->srv pointer from struct session
    - [MEDIUM] stats: split frontend and backend stats
    - [MEDIUM] http: always evaluate http-request rules before stats http-request
    - [REORG] http: move the http-request rules to proto_http
    - [BUG] http: stats were not incremented on http-request deny
    - [MINOR] checks: report it if checks fail due to socket creation error

14 years ago[MINOR] checks: report it if checks fail due to socket creation error
Willy Tarreau [Wed, 9 Mar 2011 19:38:33 +0000 (20:38 +0100)] 
[MINOR] checks: report it if checks fail due to socket creation error

If the check fails for a low-level socket error (eg: address family not
supportd), we currently ignore the status. We must report the error and
declare a failed health check in this case. The only real reason for this
would be when an IPv6 check is required on an IPv4-only system.

14 years ago[BUG] http: stats were not incremented on http-request deny
Willy Tarreau [Thu, 6 Jan 2011 17:19:50 +0000 (18:19 +0100)] 
[BUG] http: stats were not incremented on http-request deny

A counter increase was missing here.
This should be backported to 1.4 with care, as the code has changed a bit.

14 years ago[REORG] http: move the http-request rules to proto_http
Willy Tarreau [Thu, 6 Jan 2011 16:51:27 +0000 (17:51 +0100)] 
[REORG] http: move the http-request rules to proto_http

And also rename "req_acl_rule" "http_req_rule". At the beginning that
was a bit confusing to me, especially the "req_acl" list which in fact
holds what we call rules. After some digging, it appeared that some
part of the code is 100% HTTP and not just related to authentication
anymore, so let's move that part to HTTP and keep the auth-only code
in auth.c.

14 years ago[MEDIUM] http: always evaluate http-request rules before stats http-request
Willy Tarreau [Thu, 6 Jan 2011 15:53:21 +0000 (16:53 +0100)] 
[MEDIUM] http: always evaluate http-request rules before stats http-request

Right now, http-request rules are not evaluated if the URL matches the
stats request. This is quite unexpected. For instance, in the config
below, an abuser present in the abusers list will not be prevented access
to the stats.

   listen pub
        bind :8181
acl abuser src -f abusers.lst
        http-request deny if abuser
        stats uri /stats

It is not a big deal but it's not documented as such either. For 1.5, let's
have both lists be evaluated in turn, until one blocks. For 1.4 we'll simply
update the doc to indicate that.

Also instead of duplicating the code, the patch factors out the list walking
code. The HTTP auth has been moved slightly earlier, because it was set after
the header addition code, but we don't need to add headers to a request we're
dropping.

14 years ago[MEDIUM] stats: split frontend and backend stats
Willy Tarreau [Thu, 10 Mar 2011 22:25:56 +0000 (23:25 +0100)] 
[MEDIUM] stats: split frontend and backend stats

It's very annoying that frontend and backend stats are merged because we
don't know what we're observing. For instance, if a "listen" instance
makes use of a distinct backend, it's impossible to know what the bytes_out
means.

Some points take care of not updating counters twice if the backend points
to the frontend, indicating a "listen" instance. The thing becomes more
complex when we try to add support for server side keep-alive, because we
have to maintain a pointer to the backend used for last request, and to
update its stats. But we can't perform such comparisons anymore because
the counters will not match anymore.

So in order to get rid of this situation, let's have both frontend AND
backend stats in the "struct proxy". We simply update the relevant ones
during activity. Some of them are only accounted for in the backend,
while others are just for frontend. Maybe we can improve a bit on that
later, but the essential part is that those counters now reflect what
they really mean.

14 years ago[MEDIUM] add internal support for IPv6 server addresses
David du Colombier [Thu, 10 Mar 2011 21:26:24 +0000 (22:26 +0100)] 
[MEDIUM] add internal support for IPv6 server addresses

This patch turns internal server addresses to sockaddr_storage to
store IPv6 addresses, and makes the connect() function use it. This
code already works but some caveats with getaddrinfo/gethostbyname
still need to be sorted out while the changes had to be merged at
this stage of internal architecture changes. So for now the config
parser will not emit an IPv6 address yet so that user experience
remains unchanged.

This change should have absolutely zero user-visible effect, otherwise
it's a bug introduced during the merge, that should be reported ASAP.

14 years ago[MAJOR] session: remove the ->srv pointer from struct session
Willy Tarreau [Thu, 10 Mar 2011 15:55:02 +0000 (16:55 +0100)] 
[MAJOR] session: remove the ->srv pointer from struct session

This one has been removed and is now totally superseded by ->target.
To get the server, one must use target_srv(&s->target) instead of
s->srv now.

The function ensures that non-server targets still return NULL.

14 years ago[CLEANUP] stream_interface: use inline functions to manipulate targets
Willy Tarreau [Thu, 10 Mar 2011 13:03:36 +0000 (14:03 +0100)] 
[CLEANUP] stream_interface: use inline functions to manipulate targets

The connection target involves a type and a union of pointers, let's
make the code cleaner using simple wrappers.

14 years ago[MEDIUM] session: remove s->prev_srv which is not needed anymore
Willy Tarreau [Thu, 10 Mar 2011 10:42:13 +0000 (11:42 +0100)] 
[MEDIUM] session: remove s->prev_srv which is not needed anymore

s->prev_srv is used by assign_server() only, but all code paths leading
to it now take s->prev_srv from the existing s->srv. So assign_server()
can do that copy into its own stack.

If at one point a different srv is needed, we still have a copy of the
last server on which we failed a connection attempt in s->target.

14 years ago[MINOR] session: add a pointer to the new target into the session
Willy Tarreau [Thu, 10 Mar 2011 10:38:29 +0000 (11:38 +0100)] 
[MINOR] session: add a pointer to the new target into the session

When dealing with HTTP keep-alive, we'll have to know if we can reuse
an existing connection. For that, we'll have to check if the current
connection was made on the exact same target (referenced in the stream
interface).

Thus, we need to first assign the next target to the session, then
copy it to the stream interface upon connect(). Later we'll check for
equivalence between those two operations.

14 years ago[MINOR] cfgparse: only keep one of dispatch, transparent, http_proxy
Willy Tarreau [Fri, 4 Mar 2011 16:30:54 +0000 (17:30 +0100)] 
[MINOR] cfgparse: only keep one of dispatch, transparent, http_proxy

Since all of them are defined as proxy options, it's better to ensure
that at most one of them is enabled at once. The priority has been set
according to what is already performed in the backend :

   1) dispatch
   2) http_proxy
   3) transparent

14 years ago[MINOR] proxy: add PR_O2_DISPATCH to detect dispatch mode
Willy Tarreau [Fri, 4 Mar 2011 21:44:16 +0000 (22:44 +0100)] 
[MINOR] proxy: add PR_O2_DISPATCH to detect dispatch mode

Till now we used the fact that the dispatch address was not null to use
the dispatch mode. This is very unconvenient, so let's have a dedicated
option.

14 years ago[REORG] session: move the data_ctx struct to the stream interface's applet
Willy Tarreau [Thu, 10 Mar 2011 10:25:07 +0000 (11:25 +0100)] 
[REORG] session: move the data_ctx struct to the stream interface's applet

This is in fact where those parts belong to. The old data_state was replaced
by applet.state and is now initialized when the applet is registered. It's
worth noting that the applet does not need to know the session nor the
buffer anymore since everything is brought by the stream interface.

It is possible that having a separate applet struct would simplify the
code but that's not a big deal.

14 years ago[CLEANUP] stats: make all dump functions only rely on the stream interface
Willy Tarreau [Sun, 13 Feb 2011 14:27:22 +0000 (15:27 +0100)] 
[CLEANUP] stats: make all dump functions only rely on the stream interface

This will be needed to move the applet-specific data out of the session.

14 years ago[CLEANUP] session: remove data_source from struct session
Willy Tarreau [Sun, 13 Feb 2011 13:36:41 +0000 (14:36 +0100)] 
[CLEANUP] session: remove data_source from struct session

This one was only used for logging purposes, it's not needed
anymore.

14 years ago[MEDIUM] log: take the logged server name from the stream interface
Willy Tarreau [Sun, 13 Feb 2011 13:30:26 +0000 (14:30 +0100)] 
[MEDIUM] log: take the logged server name from the stream interface

With HTTP keep-alive, logging the right server name will be quite
complex because the assigned server will possibly change before we log.
Also, when we want to log accesses to an applet, it's not easy because
the applet becomes NULL again before logging.

The logged server's name is now taken from the target stored in the
stream interface. That way we can log an applet, a server name, or we
could even log a proxy or anything else if we wanted to. Ideally the
session should contain a desired target which is the one which should
be logged.

14 years ago[CLEANUP] stream_interface: remove the applet.handler pointer
Willy Tarreau [Thu, 10 Mar 2011 10:17:02 +0000 (11:17 +0100)] 
[CLEANUP] stream_interface: remove the applet.handler pointer

Now that we have the target pointer and type in the stream interface,
we don't need the applet.handler pointer anymore. That makes the code
somewhat cleaner because we know we're dealing with an applet by checking
its type instead of checking the pointer is not null.

14 years ago[MEDIUM] stream_interface: store the target pointer and type
Willy Tarreau [Fri, 4 Mar 2011 21:04:29 +0000 (22:04 +0100)] 
[MEDIUM] stream_interface: store the target pointer and type

When doing a connect() on a stream interface, some information is needed
from the server and from the backend. In some situations, we don't have
a server and only a backend (eg: peers). In other cases, we know we have
an applet and we don't want to connect to anything, but we'd still like
to have the info about the applet being used.

For this, we now store a pointer to the "target" into the stream interface.
The target describes what's on the other side before trying to connect. It
can be a server, a proxy or an applet for now. Later we'll probably have
descriptors for multiple-stage chains so that the final information may
still be found.

This will help removing many specific cases in the code. It already made
it possible to remove the "srv" and "be" parameters to tcpv4_connect_server().

14 years ago[REORG] tcp: make tcpv4_connect_server() take the target address from the SI
Willy Tarreau [Thu, 3 Mar 2011 17:27:32 +0000 (18:27 +0100)] 
[REORG] tcp: make tcpv4_connect_server() take the target address from the SI

The address is now available in the stream interface, no need to pass it by
argument.

14 years ago[REORG] session: move client and server address to the stream interface
Willy Tarreau [Thu, 3 Mar 2011 16:42:23 +0000 (17:42 +0100)] 
[REORG] session: move client and server address to the stream interface

This will be needed very soon for the keep-alive.

14 years ago[REORG] stream_interface: split the struct members in 3 parts
Willy Tarreau [Thu, 3 Mar 2011 16:08:11 +0000 (17:08 +0100)] 
[REORG] stream_interface: split the struct members in 3 parts

Those 3 parts are the buffer side, the remote side and the communication
functions. This change has no functional effect but is needed to proceed
further.

14 years ago[REORG] stream_interface: move the st0, st1 and private members to the applet
Willy Tarreau [Sun, 13 Feb 2011 12:25:14 +0000 (13:25 +0100)] 
[REORG] stream_interface: move the st0, st1 and private members to the applet

Those fields are only used by the applets, so let's move them to the
struct.

14 years ago[MINOR] stream_interface: make use of an applet descriptor for IO handlers
Willy Tarreau [Sun, 13 Feb 2011 12:16:36 +0000 (13:16 +0100)] 
[MINOR] stream_interface: make use of an applet descriptor for IO handlers

I/O handlers are still delicate to manipulate. They have no type, they're
just raw functions which have no knowledge of themselves. Let's have them
declared as applets once for all. That way we can have multiple applets
share the same handler functions and we can store their names there. When
we later need to add more parameters (eg: usage stats), we'll be able to
do so in the applets themselves.

The CLI functions has been prefixed with "cli" instead of "stats" as it's
clearly what is going on there.

The applet descriptor in the stream interface should get all the applet
specific data (st0, ...) but this will be done in the next patch so that
we don't pollute this one too much.

14 years ago[BUG] config: don't crash on empty pattern files.
Willy Tarreau [Wed, 9 Mar 2011 06:27:02 +0000 (07:27 +0100)] 
[BUG] config: don't crash on empty pattern files.

Both Hank A. Paulson and Rob at pixsense reported a crash when
loading ACLs from a pattern file which contains empty lines.

From the tests, it appears that only files that contain nothing
but empty lines are causing that (in the past they would have had
their line feeds loaded as patterns).

The crash happens in the free_pattern() call which doesn't like to
be called with a NULL pattern. Let's make it accept it so that it's
more in line with the standard uses of free() which ignores NULLs.

14 years ago[BUG] stats: admin web interface must check the proxy state
Cyril Bonté [Thu, 3 Mar 2011 20:05:17 +0000 (21:05 +0100)] 
[BUG] stats: admin web interface must check the proxy state

Similar to the stats socket bug, we must check that the proxy is not disabled
before trying to enable/disable a server.

Even if a disabled proxy is not displayed, someone can inject a faulty proxy
name in the POST parameters. So, we must ensure that no disabled proxy can be
used.

14 years ago[BUG] stats: admin commands must check the proxy state
Cyril Bonté [Thu, 3 Mar 2011 19:49:04 +0000 (20:49 +0100)] 
[BUG] stats: admin commands must check the proxy state

As reported by Bryan Talbot, enabling and disabling a server in a disabled
proxy causes a segfault.

Changing the weight can also cause a similar segfault.

14 years ago[DOC] internal: reflect the fact that SI_ST_ASS is transient
Willy Tarreau [Thu, 24 Feb 2011 16:24:48 +0000 (17:24 +0100)] 
[DOC] internal: reflect the fact that SI_ST_ASS is transient

This state might appear before process_session() (eg: when the session is
first initialized), but does not remain after process_session() returns.

14 years ago[DOC] update ROADMAP
Willy Tarreau [Tue, 1 Mar 2011 20:28:51 +0000 (21:28 +0100)] 
[DOC] update ROADMAP

add wish to kill existing sessions when entering maintenance mode.

14 years ago[TESTS] update the url_param regression test to test check_post too
Willy Tarreau [Tue, 1 Mar 2011 19:43:27 +0000 (20:43 +0100)] 
[TESTS] update the url_param regression test to test check_post too

14 years ago[BUG] http: balance url_param did not work with first parameters on POST
Willy Tarreau [Tue, 1 Mar 2011 19:35:49 +0000 (20:35 +0100)] 
[BUG] http: balance url_param did not work with first parameters on POST

Bryan Talbot reported that POST requests with a query string were not
correctly processed if the hash parameter was the first one, because
the delimiter that was looked for to trigger the parsing was '&' instead
of '?'.

Also, while checking the code, it became apparent that it was enough for
a query string to be present in the request for POST parameters to be
ignored, even if the url_param was in the body and not in the URL.

The code has then been fixed like this :
   1) look for URL param. If found, return it.
   2) if no URL param was found and method is POST, then look it up into
      the body

The code now seems to pass all request combinations.

This patch must be backported to 1.4 since 1.4 is equally broken right now.

14 years ago[BUG] http: fix computation of message body length after forwarding has started
Willy Tarreau [Tue, 1 Mar 2011 19:30:48 +0000 (20:30 +0100)] 
[BUG] http: fix computation of message body length after forwarding has started

Till now, the forwarding code was making use of the hdr_content_len member
to hold the size of the last chunk parsed. As such, it was reset after being
scheduled for forwarding. The issue is that this entry was reset before the
data could be viewed by backend.c in order to parse a POST body, so the
"balance url_param check_post" did not work anymore.

In order to fix this, we need two things :
  - the chunk size (reset upon every forward)
  - the total body size (not reset)

hdr_content_len was thus replaced by the former (hence the size of the patch)
as it makes more sense to have it stored that way than the way around.

This patch should be backported to 1.4 with care, considering that it affects
the forwarding code.

14 years ago[BUG] http: fix possible incorrect forwarded wrapping chunk size
Willy Tarreau [Tue, 1 Mar 2011 19:04:36 +0000 (20:04 +0100)] 
[BUG] http: fix possible incorrect forwarded wrapping chunk size

It seems like if a response message is chunked and the chunk size wraps
at the end of the buffer and the crlf sequence is incomplete, then we
can forward a wrong chunk size due to incorrect handling of the wrapped
size. It seems extremely unlikely to occur on real traffic (no reason to
have half of the CRLF after a chunk) but nothing prevents it from being
possible.

This fix must be backported to 1.4.

14 years ago[DOC] fix minor typo in "usesrc"
Willy Tarreau [Tue, 1 Mar 2011 08:51:54 +0000 (09:51 +0100)] 
[DOC] fix minor typo in "usesrc"

Reported by Gus Zader.

14 years ago[BUG] acl: fd leak when reading patterns from file
Willy Tarreau [Sat, 26 Feb 2011 14:14:15 +0000 (15:14 +0100)] 
[BUG] acl: fd leak when reading patterns from file

The fd is not closed after patterns have successfully been read from
a file. Bug reported by Bertrand Jacquin. Should be backported to 1.4.

14 years ago[MINOR] config: warn if response-only conditions are used in "redirect" rules
Willy Tarreau [Wed, 23 Feb 2011 14:24:42 +0000 (15:24 +0100)] 
[MINOR] config: warn if response-only conditions are used in "redirect" rules

14 years ago[MINOR] acl: srv_id is only valid in responses
Willy Tarreau [Wed, 23 Feb 2011 14:24:16 +0000 (15:24 +0100)] 
[MINOR] acl: srv_id is only valid in responses

14 years ago[MINOR] acl: add ability to check for internal response-only parameters
Willy Tarreau [Wed, 23 Feb 2011 14:17:24 +0000 (15:17 +0100)] 
[MINOR] acl: add ability to check for internal response-only parameters

Some parameters are known to the response only (eg: the server which processed
it). Let's have a flag for that.

14 years ago[BUG] acl: srv_id must return no match when the server is NULL
Willy Tarreau [Wed, 23 Feb 2011 13:27:06 +0000 (14:27 +0100)] 
[BUG] acl: srv_id must return no match when the server is NULL

Reported by Hervé Commowick, causes crashes when the server is not known.

14 years ago[BUG] startup: set the rlimits before binding ports, not after.
Willy Tarreau [Wed, 16 Feb 2011 10:10:36 +0000 (11:10 +0100)] 
[BUG] startup: set the rlimits before binding ports, not after.

As reported by the Loadbalancer.org team, it was not possible to bind
more than 1024 ports. This is because the process' limits were set after
trying to bind the sockets, which defeats their purpose.

This fix must be backported to 1.4 and 1.3.

14 years ago[BUG] cfgparse: correctly count one socket per port in ranges
Willy Tarreau [Wed, 16 Feb 2011 10:08:57 +0000 (11:08 +0100)] 
[BUG] cfgparse: correctly count one socket per port in ranges

We used to only count one socket instead of one per listener. This makes
the socket count wrong, preventing from automatically computing the proper
number of sockets to bind.

This fix must be backported to 1.4 and 1.3.

14 years ago[BUG] http: use correct ACL pointer when evaluating authentication
Willy Tarreau [Thu, 6 Jan 2011 15:44:39 +0000 (16:44 +0100)] 
[BUG] http: use correct ACL pointer when evaluating authentication

req_acl was used instead of req_acl_final. As a matter of luck, both
happen to be the same at this point, but this is not granted in the
future.

This fix should be backported to 1.4.

14 years ago[DOC] fix typos (http-request instead of http-check)
Willy Tarreau [Thu, 6 Jan 2011 15:36:10 +0000 (16:36 +0100)] 
[DOC] fix typos (http-request instead of http-check)

14 years ago[DOC] fix minor typo in the proxy protocol doc
Willy Tarreau [Sun, 13 Feb 2011 08:17:39 +0000 (09:17 +0100)] 
[DOC] fix minor typo in the proxy protocol doc

As reported by David Swift, stunnel's option is "sendproxy".

14 years ago[MINOR] stats: add support for several packets in stats admin
Cyril Bonté [Thu, 10 Feb 2011 21:54:44 +0000 (22:54 +0100)] 
[MINOR] stats: add support for several packets in stats admin

Some browsers send POST requests in several packets, which was not supported
by the "stats admin" function.

This patch allows to wait for more data when they are not fully received
(we are still limited to a certain size defined by the buffer size minus its
reserved space).
It also adds support for the "Expect: 100-Continue" header.

14 years ago[BUG] http: update the header list's tail when removing the last header
Willy Tarreau [Sat, 12 Feb 2011 12:07:35 +0000 (13:07 +0100)] 
[BUG] http: update the header list's tail when removing the last header

Stefan Behte reported a strange case where depending on the position of
the Connection header in the header list, some headers added after it
were or were not usable in "balance hdr()". The reason is that when the
last header is removed, the list's tail was not updated, so any header
added after that one was not visible from the list.

This fix must be backported to 1.4 and possibly 1.3.

14 years ago[MINOR] cfgparse: Check whether the path given for the stats socket actually fits...
Andreas Kohn [Wed, 19 Jan 2011 19:29:32 +0000 (20:29 +0100)] 
[MINOR] cfgparse: Check whether the path given for the stats socket actually fits into the sockaddr_un structure to avoid truncation.

while working further on the changes to allow for dynamic
adding/removing of backend servers we noticed a potential problem: the
path given for the 'stats socket' global option may get truncated when
copying it into the sockaddr_un.sun_path field.

Attached patch checks the length, and reports an error if truncation
would happen.

This issue was noticed by Joerg Sonnenberger <joerg@NetBSD.org>.

14 years ago[BUILD] frontend: shut a warning with TCP_MAXSEG
Willy Tarreau [Wed, 5 Jan 2011 14:42:54 +0000 (15:42 +0100)] 
[BUILD] frontend: shut a warning with TCP_MAXSEG

src/frontend.c: In function 'frontend_accept':
src/frontend.c:110: warning: pointer targets in passing argument 5 of 'getsockopt' differ in signedness

The argument should be socklen_t and not int.

14 years ago[MINOR] checks: add PostgreSQL health check
Rauf Kuliyev [Tue, 4 Jan 2011 14:14:13 +0000 (15:14 +0100)] 
[MINOR] checks: add PostgreSQL health check

I have written a small patch to enable a correct PostgreSQL health check
It works similar to mysql-check with the very same parameters.

E.g.:
listen pgsql 127.0.0.1:5432
   mode tcp
   option pgsql-check user pgsql
   server masterdb pgsql.server.com:5432 check inter 10000

14 years ago[MINOR] http: improve url_param pattern extraction to ignore empty values
Willy Tarreau [Tue, 4 Jan 2011 13:57:34 +0000 (14:57 +0100)] 
[MINOR] http: improve url_param pattern extraction to ignore empty values

It's better to avoid sticking on empty parameter values, as this almost
always indicates a missing parameter. Otherwise it's easy to enter a
situation where all new visitors stick to the same server.

14 years ago[REVERT] undo the stick-table string key lookup fixes
Willy Tarreau [Tue, 4 Jan 2011 13:50:49 +0000 (14:50 +0100)] 
[REVERT] undo the stick-table string key lookup fixes

Revert commits 035da6d1b0c436b85add48bc22120aa814c9cab9 and
f18b5f21bafef909901b7b5cf95625a63e609c75.

These fixes were wrong. They worked but they were fixing the symptom
instead of the root cause of the problem. The real issue was in the
ebtree lookup code and it has been fixed now so these patches are not
needed anymore. It's better not to copy memory blocks when we don't
need to, so let's revert them.

14 years ago[OPTIM] ebtree: inline ebst_lookup_len and ebis_lookup_len
Willy Tarreau [Tue, 4 Jan 2011 13:33:13 +0000 (14:33 +0100)] 
[OPTIM] ebtree: inline ebst_lookup_len and ebis_lookup_len

(from ebtree 6.0.5)

Both of them are very short and rely on another non-inlined lookup function,
so it's pointless to have them as pure functions, it wastes space.
(cherry picked from commit 1e68d6fef815f759304d4cc0e65f957689e19a7a)

14 years ago[OPTIM] ebtree: ebmb_lookup: reduce stack usage by moving the return code out of...
Willy Tarreau [Tue, 4 Jan 2011 13:07:36 +0000 (14:07 +0100)] 
[OPTIM] ebtree: ebmb_lookup: reduce stack usage by moving the return code out of the loop

(from ebtree 6.0.5)

Last bugfix has introduced a de-optimization in the lookup function because
it artificially extended the scope of some local variables, which resulted in
higher stack usage and more numerous moves between stack and registers.

We can reduce that by moving the return code out of the loop, because gcc
notices that it never needs both "troot" and "node" at the same time and
can use the same register for both. Doing so has reduced the code size by
39 bytes for the lookup function alone, and has sensibly reduced the
instruction dependencies caused by data moves.
(cherry picked from commit 59be3cdb96296b65a57aff30cc203269f9a94ebe)

It should be backported to 1.4 if previous ebtree fix is backported.

14 years ago[BUG] ebtree: fix ebmb_lookup() with len smaller than the tree's keys
Willy Tarreau [Tue, 4 Jan 2011 12:21:06 +0000 (13:21 +0100)] 
[BUG] ebtree: fix ebmb_lookup() with len smaller than the tree's keys

(from ebtree 6.0.5)

ebmb_lookup() is used by ebst_lookup_len() to lookup a string starting
with a known substring. Since the substring does not necessarily end
with a zero, we must absolutely ensure that the comparison stops at
<len> bytes, otherwise we can end up comparing crap and most often
returning the wrong node in case of multiple matches.

ebim_lookup() was fixed too by resyncing it with ebmb_lookup().
(cherry picked from commit 98eba315aa2c3285181375d312bcb770f058fd2b)

This should be backported to 1.4 though it's not critical there.

14 years ago[BUG] stick-table: use the private buffer when padding strings
Willy Tarreau [Tue, 4 Jan 2011 05:29:44 +0000 (06:29 +0100)] 
[BUG] stick-table: use the private buffer when padding strings

Commit 035da6d1b0c436b85add48bc22120aa814c9cab9 was incorrect as it
could modify a live buffer. We must first ensure that we're on the
private buffer or perform a copy before modifying the data.

14 years ago[BUG] acl: fix handling of empty lines in pattern files
Willy Tarreau [Mon, 3 Jan 2011 20:04:10 +0000 (21:04 +0100)] 
[BUG] acl: fix handling of empty lines in pattern files

Gabriel Sosa reported that haproxy unexpectedly reports an error
when a pattern file loaded by an ACL contains an empty line. The
test was present but inefficient as it did not consider the '\n'
as the end of the line. This fix relies on the line length instead.

It should be backported to 1.4.

14 years ago[MINOR] http: add pattern extraction method to stick on query string parameter
David Cournapeau [Thu, 23 Dec 2010 11:55:41 +0000 (20:55 +0900)] 
[MINOR] http: add pattern extraction method to stick on query string parameter

This is an updated version of my patch for url parameter extraction on
stick table. It adds "url_param(name)" as a possible stick method.

14 years ago[BUG] stick-table: correctly terminate string keys during lookups
Willy Tarreau [Sun, 2 Jan 2011 18:31:23 +0000 (19:31 +0100)] 
[BUG] stick-table: correctly terminate string keys during lookups

If a key to be looked up is extracted from data without being padded
and if it matches the beginning of another stored key, it is not
found in subsequent lookups because it does not end with a zero.

This bug was discovered and diagnosed by David Cournapeau.

14 years ago[MINOR] log: ability to override the syslog tag
Kevinm [Wed, 22 Dec 2010 16:08:21 +0000 (16:08 +0000)] 
[MINOR] log: ability to override the syslog tag

One of the requirements we have is to run multiple instances of haproxy on a
single host; this is so that we can split the responsibilities (and change
permissions) between product teams. An issue we ran up against is how we
would distinguish between the logs generated by each instance. The solution
we came up with (please let me know if there is a better way) is to override
the application tag written to syslog. We can then configure syslog to write
these to different files.

I have attached a patch adding a global option 'log-tag' to override the
default syslog tag 'haproxy' (actually defaults to argv[0]).

14 years ago[MINOR] tcp: add support for dynamic MSS setting
Willy Tarreau [Fri, 24 Dec 2010 14:26:39 +0000 (15:26 +0100)] 
[MINOR] tcp: add support for dynamic MSS setting

By passing a negative value to the "mss" argument of "bind" lines, it
becomes possible to subtract this value to the MSS advertised by the
client, which results in segments smaller than advertised. The effect
is useful with some TCP stacks which ACK less often when segments are
not full, because they only ACK every other full segment as suggested
by RFC1122.

NOTE: currently this has no effect on Linux kernel 2.6, a kernel patch
is still required to change the MSS of established connections.

14 years ago[MINOR] log: add support for passing the forwarded hostname
Joe Williams [Wed, 29 Dec 2010 16:05:48 +0000 (17:05 +0100)] 
[MINOR] log: add support for passing the forwarded hostname

Haproxy does not include the hostname rather the IP of the machine in
the syslog headers it sends. Unfortunately this means that for each log
line rsyslog does a reverse dns on the client IP and in the case of
non-routable IPs one gets the public hostname not the internal one.

While this is valid according to RFC3164 as one might imagine this is
troublsome if you have some machines with public IPs, internal IPs, no
reverse DNS entries, etc and you want a standardized hostname based log
directory structure. The rfc says the preferred value is the hostname.

This patch adds a global "log-send-hostname" statement which accepts an
optional string to force the host name. If unset, the local host name
is used.

14 years ago[BUG] http: fix http-pretend-keepalive and httpclose/tunnel mode
Cyril Bonté [Wed, 29 Dec 2010 08:36:56 +0000 (09:36 +0100)] 
[BUG] http: fix http-pretend-keepalive and httpclose/tunnel mode

Since haproxy 1.4.9, combining option httpclose and option
http-pretend-keepalive can leave the connections opened until the backend
keep-alive timeout is reached, providing bad performances.
The same can occur when the proxy is in tunnel mode.

This patch ensures that the server side connection is closed after the
response and ignore http-pretend-keepalive in tunnel mode.

14 years ago[BUG] session: release slot before processing pending connections
Willy Tarreau [Wed, 29 Dec 2010 13:32:28 +0000 (14:32 +0100)] 
[BUG] session: release slot before processing pending connections

When a connection error is encountered on a server and the server's
connection pool is full, pending connections are not woken up because
the current connection is still accounted for on the server, so it
still appears full. This becomes visible on a server which has
"maxconn 1" because the pending connections will only be able to
expire in the queue.

Now we take care of releasing our current connection before trying to
offer it to another pending request, so that the server can accept a
next connection.

This patch should be backported to 1.4.

14 years ago[CRITICAL] session: correctly leave turn-around and queue states on abort
Willy Tarreau [Wed, 29 Dec 2010 13:03:02 +0000 (14:03 +0100)] 
[CRITICAL] session: correctly leave turn-around and queue states on abort

When a client connection aborts while the server-side connection is in
turn-around after a failed connection attempt, the turn-around timeout
is reset in shutw() but the state is not changed. The session then
remains stuck in this state forever. Change the QUE and TAR states to
DIS just as we do for CER to fix this.

This patch should be backported to 1.4.

14 years ago[BUG] http: fix incorrect error reporting during data transfers
Willy Tarreau [Wed, 29 Dec 2010 10:23:27 +0000 (11:23 +0100)] 
[BUG] http: fix incorrect error reporting during data transfers

We've had several issues related to data transfers. First, if a
client aborted an upload before the server started to respond, it
would get a 502 followed by a 400. The same was true (in the other
way around) if the server suddenly aborted while the client was
uploading the data.

The flags reported in the logs were misleading. Request errors could
be reported while the transfer was stopped during the data phase. The
status codes could also be overwritten by a 400 eventhough the start
of the response was transferred to the client.

The stats were also wrong in case of data aborts. The server or the
client could sometimes be miscredited for being the author of the
abort depending on where the abort was detected. Some client aborts
could also be accounted as request errors and some server aborts as
response errors.

Now it seems like all such issues are fixed. Since we don't have a
specific state for data flowing from the client to the server
before the server responds, we're still counting the client aborted
transfers as "CH", and they become "CD" when the server starts to
respond. Ideally a "P" state would be desired.

This patch should be backported to 1.4.

14 years ago[CLEANUP] frontend: only apply TCP-specific settings to TCP/TCP6 sockets
Willy Tarreau [Fri, 24 Dec 2010 13:49:37 +0000 (14:49 +0100)] 
[CLEANUP] frontend: only apply TCP-specific settings to TCP/TCP6 sockets

It's useless to apply keep-alive or lingering to non-TCP sockets.

14 years ago[BUG] http: analyser optimizations broke pipelining
Willy Tarreau [Fri, 17 Dec 2010 06:13:42 +0000 (07:13 +0100)] 
[BUG] http: analyser optimizations broke pipelining

HTTP pipelining currently needs to monitor the response buffer to wait
for some free space to be able to send a response. It was not possible
for the HTTP analyser to be called based on response buffer activity.
Now we introduce a new buffer flag BF_WAKE_ONCE which is set when the
HTTP request analyser is set on the response buffer and some activity
is detected. This is not clean at all but once of the only ways to fix
the issue before we make it possible to register events for analysers.

Also it appeared that one realign condition did not cover all cases.

14 years ago[MINOR] acl: add be_id/srv_id to match backend's and server's id
Hervé COMMOWICK [Wed, 15 Dec 2010 13:04:51 +0000 (14:04 +0100)] 
[MINOR] acl: add be_id/srv_id to match backend's and server's id

These ones can be useful in responses.

14 years ago[MINOR] add warnings on features not compatible with multi-process mode
Cyril Bonté [Tue, 14 Dec 2010 21:48:49 +0000 (22:48 +0100)] 
[MINOR] add warnings on features not compatible with multi-process mode

Using haproxy in multi-process mode (nbproc > 1), some features can be
not fully compatible or not work at all. haproxy will now display a warning on
startup for :
- appsession
- sticking rules
- stats / stats admin
- stats socket
- peers (fatal error in that case)

14 years ago[DOC] fix ignore-persist documentation
Cyril Bonté [Tue, 14 Dec 2010 21:48:23 +0000 (22:48 +0100)] 
[DOC] fix ignore-persist documentation

During the documentation of the "ignore-persist" keyword, I documented an
invalid "option ignore-persist" and forgot to remove it. It's time to fix it.