haproxy/include/proto
Christopher Faulet 67957bd59e MAJOR: dns: Refactor the DNS code
This is a huge patch with many changes, all about the DNS. Initially, the idea
was to update the DNS part to ease the threads support integration. But quickly,
I started to refactor some parts. And after several iterations, it was
impossible for me to commit the different parts atomically. So, instead of
adding tens of patches, often reworking the same parts, it was easier to merge
all my changes in a uniq patch. Here are all changes made on the DNS.

First, the DNS initialization has been refactored. The DNS configuration parsing
remains untouched, in cfgparse.c. But all checks have been moved in a post-check
callback. In the function dns_finalize_config, for each resolvers, the
nameservers configuration is tested and the task used to manage DNS resolutions
is created. The links between the backend's servers and the resolvers are also
created at this step. Here no connection are kept alive. So there is no needs
anymore to reopen them after HAProxy fork. Connections used to send DNS queries
will be opened on demand.

Then, the way DNS requesters are linked to a DNS resolution has been
reworked. The resolution used by a requester is now referenced into the
dns_requester structure and the resolution pointers in server and dns_srvrq
structures have been removed. wait and curr list of requesters, for a DNS
resolution, have been replaced by a uniq list. And Finally, the way a requester
is removed from a DNS resolution has been simplified. Now everything is done in
dns_unlink_resolution.

srv_set_fqdn function has been simplified. Now, there is only 1 way to set the
server's FQDN, independently it is done by the CLI or when a SRV record is
resolved.

The static DNS resolutions pool has been replaced by a dynamoc pool. The part
has been modified by Baptiste Assmann.

The way the DNS resolutions are triggered by the task or by a health-check has
been totally refactored. Now, all timeouts are respected. Especially
hold.valid. The default frequency to wake up a resolvers is now configurable
using "timeout resolve" parameter.

Now, as documented, as long as invalid repsonses are received, we really wait
all name servers responses before retrying.

As far as possible, resources allocated during DNS configuration parsing are
releases when HAProxy is shutdown.

Beside all these changes, the code has been cleaned to ease code review and the
doc has been updated.
2017-10-31 11:36:12 +01:00
..
acl.h MINOR: acl: Pass the ACLs as an explicit parameter of build_acl_cond 2017-10-31 11:36:12 +01:00
action.h MINOR: action: Add function to check rules using an action ACT_ACTION_TRK_* 2017-10-31 11:36:12 +01:00
applet.h MAJOR: applet: applet scheduler rework. 2017-06-27 14:38:02 +02:00
arg.h MINOR: sample: Moves ARGS underlying type from 32 to 64 bits. 2016-03-15 22:11:52 +01:00
auth.h MEDIUM: pattern: The match function browse itself the list or the tree. 2014-03-17 18:06:07 +01:00
backend.h MEDIUM: check: server states and weight propagation re-work 2017-09-05 15:23:16 +02:00
channel.h MINOR: channel: make the channel be a const in all {ci,co}_get* functions 2017-10-19 15:01:08 +02:00
checks.h MAJOR/REORG: dns: DNS resolution task and requester queues 2017-06-02 11:58:54 +02:00
cli.h MINOR: cli: create new function cli_has_level() to validate permissions 2016-11-24 16:59:27 +01:00
compression.h REORG: filters: Prepare creation of the HTTP compression filter 2016-02-09 14:53:15 +01:00
connection.h MEDIUM: ssl: Handle early data with OpenSSL 1.1.1 2017-10-27 10:54:05 +02:00
dns.h MAJOR: dns: Refactor the DNS code 2017-10-31 11:36:12 +01:00
fd.h MINOR: fd: Add fd_update_events function 2017-09-05 15:43:09 +02:00
filters.h CLEANUP: filters: use the function registration to initialize all proxies 2016-12-21 21:30:54 +01:00
flt_http_comp.h MAJOR: filters/http: Rewrite the HTTP compression as a filter 2016-02-09 14:53:15 +01:00
freq_ctr.h MINOR: freq_ctr: Return the new value after an update 2017-09-05 11:55:07 +02:00
frontend.h REORG/MAJOR: session: rename the "session" entity to "stream" 2015-04-06 11:23:56 +02:00
h1.h MINOR: h1: store the status code in the H1 message 2017-10-31 08:43:29 +01:00
hdr_idx.h CLEANUP: hdr_idx: make some function arguments const where possible 2017-07-17 21:11:30 +02:00
hlua_fcn.h MINOR: lua: add utility function for check boolean argument 2016-11-24 21:35:10 +01:00
hlua.h BUILD/MINOR: lua: ensure that hlua_ctx_destroy is properly defined 2015-06-17 20:18:54 +02:00
lb_chash.h [MEDIUM] backend: implement consistent hashing variation 2009-10-09 07:17:58 +02:00
lb_fas.h MEDIUM: backend: add the 'first' balancing algorithm 2012-02-21 22:27:27 +01:00
lb_fwlc.h [CLEANUP] backend: move LB algos to individual files 2009-10-01 11:19:37 +02:00
lb_fwrr.h [CLEANUP] backend: move LB algos to individual files 2009-10-01 11:19:37 +02:00
lb_map.h [MINOR] lb_map: reorder code in order to ease integration of new hash functions 2009-10-01 21:11:15 +02:00
listener.h MINOR: listener: new function listener_release 2017-09-15 11:49:52 +02:00
log.h MINOR: logs: Use dedicated function to init/deinit log buffers 2017-09-05 10:29:31 +02:00
map.h MINOR: samples: rename some struct member from "smp" to "data" 2015-08-20 17:13:46 +02:00
obj_type.h MINOR: obj: Add a new type of object, OBJ_TYPE_SRVRQ. 2017-08-09 16:32:49 +02:00
openssl-compat.h MINOR: ssl: build with recent BoringSSL library 2017-10-24 19:57:16 +02:00
pattern.h BUG/MEDIUM: map/acl: fix unwanted flags inheritance. 2017-07-04 10:45:53 +02:00
payload.h REORG/MAJOR: session: rename the "session" entity to "stream" 2015-04-06 11:23:56 +02:00
peers.h MAJOR: peers: peers protocol version 2.0 2015-05-29 15:50:33 +02:00
pipe.h [MEDIUM] introduce pipe pools 2009-01-25 13:49:53 +01:00
port_range.h [MEDIUM] add support for binding to source port ranges during connect 2009-06-10 12:23:32 +02:00
proto_http.h MINOR: action: Use trk_idx instead of tcp/http_trk_idx 2017-10-31 11:36:12 +01:00
proto_tcp.h MINOR: protocols: register the ->add function and stop calling them directly 2017-09-15 11:49:52 +02:00
proto_udp.h CLEANUP: fix inconsistency between fd->iocb, proto->accept and accept() 2016-04-14 11:18:22 +02:00
protocol.h MEDIUM: protocol: use a family array to index the protocol handlers 2015-02-28 23:12:31 +01:00
proxy.h MINOR: proxy: Don't close FDs if not our proxy. 2017-04-13 19:15:17 +02:00
queue.h MEDIUM: check: server states and weight propagation re-work 2017-09-05 15:23:16 +02:00
raw_sock.h CLEANUP: connection: unexport raw_sock and ssl_sock 2016-12-22 23:26:38 +01:00
sample.h MINOR: samples: Handle the type SMP_T_METH in smp_is_safe and smp_is_rw 2017-07-24 17:16:00 +02:00
server.h MAJOR: dns: Refactor the DNS code 2017-10-31 11:36:12 +01:00
session.h MINOR: session: introduce session_new() 2015-04-06 11:37:33 +02:00
shctx.h MINOR: shctx: rename lock functions 2017-10-31 03:49:44 +01:00
signal.h CLEANUP: includes: fix includes for a number of users of fd.h 2012-09-03 20:49:14 +02:00
spoe.h BUG/MINOR: Wrong type used as argument for spoe_decode_buffer(). 2017-08-22 11:27:20 +02:00
ssl_sock.h MEDIUM: shctx: separate ssl and shctx 2017-10-31 03:49:40 +01:00
stats.h BUG/MINOR: stats: make field_str() return an empty string on NULL 2016-11-26 15:58:37 +01:00
stick_table.h MINOR: stick-tables: Make static_table_key a struct variable instead of a pointer 2017-09-05 10:35:07 +02:00
stream_interface.h MINOR: stream-int: use conn_full_close() instead of conn_force_close() 2017-10-22 09:54:18 +02:00
stream.h MINOR: stream: provide a new stream creation function for connections 2017-08-30 07:06:39 +02:00
task.h MINOR: tasks: Move Lua notification from Lua to tasks 2017-09-11 18:59:40 +02:00
tcp_rules.h MINOR: action: Use trk_idx instead of tcp/http_trk_idx 2017-10-31 11:36:12 +01:00
template.h [CLEANUP] included common/version.h everywhere 2006-06-29 18:54:54 +02:00
vars.h MINOR: vars: Add 'unset-var' action/converter 2016-11-09 22:57:01 +01:00