haproxy/include/types
Willy Tarreau 7764a57d32 BUG/MEDIUM: threads: cpu-map designating a single thread/process are ignored
Since commit 81492c989 ("MINOR: threads: flatten the per-thread cpu-map"),
we don't keep the proc*thread matrix anymore to represent the full binding
possibilities, but only the proc and thread ones. The problem is that the
per-process binding is not the same for each thread and for the process,
and the proc[] array was assumed to store the per-proc first thread value
when doing this change. Worse, the logic present there tries to deal with
thread ranges and process ranges in a way which automatically exclused the
other possibility (since ranges cannot be used on both) but as such fails
to apply changes if neither the process nor the thread is expressed as a
range.

The real problem comes from the fact that specifying cpu-map 1/1 doesn't
yet reveal if the per-process mask or the per-thread mask needs to be
updated. In practice it's the thread one but then the current storage
doesn't allow to store the binding of the first thread of each other
process in nbproc>1 configurations.

When removing the proc*thread matrix, what ought to have been kept was
both the thread column for process 1 and the process line for threads 1,
but instead only the thread column was kept. This patch reintroduces the
storage of the configuration for the first thread of each process so that
it is again possible to store either the per-thread or per-process
configuration.

As a partial workaround for existing configurations, it is possible to
systematically indicate at least two processes or two threads at once
and map them by pairs or more so that at least two values are present
in the range. E.g :

  # set processes 1-4 to cpus 0-3 :

     cpu-map auto:1-4/1 0 1 2 3
  # or:
     cpu-map 1-2/1 0 1
     cpu-map 2-3/1 2 3

  # set threads 1-4 to cpus 0-3 :

     cpu-map auto:1/1-4 0 1 2 3
  # or :
     cpu-map 1/1-2 0 1
     cpu-map 3/3-4 2 3

This fix must be backported to 2.0.
2019-07-16 15:23:09 +02:00
..
acl.h
action.h MINOR: action: Add the return code ACT_RET_DONE for actions 2019-07-05 14:26:14 +02:00
activity.h MINOR: activity: report the number of failed pool/buffer allocations 2019-05-28 17:25:21 +02:00
applet.h BUG/MINOR: mworker/cli: don't output a \n before the response 2019-07-01 15:34:11 +02:00
arg.h MEDIUM: stick-table: Stop handling stick-tables as proxies. 2019-05-07 06:54:06 +02:00
auth.h
backend.h
capture.h
channel.h
checks.h MEDIUM: connection: Upstream SOCKS4 proxy support 2019-05-31 17:24:06 +02:00
cli.h
compression.h
connection.h CLEANUP: connection: rename the wait_event.task field to .tasklet 2019-06-14 14:42:29 +02:00
counters.h
dict.h MINOR: dict: Store the length of the dictionary entries. 2019-06-07 15:47:54 +02:00
dns.h BUG/MEDIUM: dns: make the port numbers unsigned 2019-05-22 20:07:45 +02:00
fd.h BUG/MEDIUM: fd/threads: fix excessive CPU usage on multi-thread accept 2019-07-09 10:41:24 +02:00
filters.h MEDIUM: streams: Add the ability to retry a request on L7 failure. 2019-05-04 10:19:56 +02:00
freq_ctr.h
global.h BUG/MEDIUM: threads: cpu-map designating a single thread/process are ignored 2019-07-16 15:23:09 +02:00
hdr_idx.h
hlua.h MEDIUM: regex: modify regex_comp() to atomically allocate/free the my_regex struct 2019-05-07 06:58:15 +02:00
http_htx.h
lb_chash.h
lb_fas.h
lb_fwlc.h
lb_fwrr.h
lb_map.h
listener.h CLEANUP: ssl: never include openssl/*.h outside of openssl-compat.h anymore 2019-05-10 09:36:42 +02:00
log.h MINOR: log: Enable the log sampling and load-balancing feature. 2019-04-30 09:25:09 +02:00
mailers.h
map.h
obj_type.h MINOR: obj_type: new object type for struct stream 2019-04-23 11:35:56 +02:00
pattern.h
peers.h MINOR: peers: Optimization for dictionary cache lookup. 2019-06-07 15:47:54 +02:00
pipe.h
port_range.h BUG/MEDIUM: port_range: Make the ring buffer lock-free. 2019-04-30 15:10:17 +02:00
proto_http.h MEDIUM: sessions: Introduce session flags. 2019-05-29 15:41:47 +02:00
proto_udp.h
protocol_buffers.h
protocol.h MEDIUM: tcp: add the "tfo" option to support TCP fastopen on the server 2019-05-06 22:29:39 +02:00
proxy.h MINOR: proxy: Add a "server by name" tree to proxy. 2019-06-05 08:33:35 +02:00
queue.h
sample.h
server.h MEDIUM: server: server-state global file stored in a tree 2019-06-17 13:40:42 +02:00
session.h MEDIUM: sessions: Introduce session flags. 2019-05-29 15:41:47 +02:00
shctx.h
signal.h
spoe.h BUG/MEDIUM: spoe: arg len encoded in previous frag frame but len changed 2019-04-29 16:02:05 +02:00
ssl_sock.h CLEANUP: ssl: make inclusion of openssl headers safe 2019-05-10 09:58:43 +02:00
stats.h MINOR: raw_sock: report global traffic statistics 2019-05-23 11:45:38 +02:00
stick_table.h MINOR: stick-table: Add "server_name" new data type. 2019-06-05 08:33:35 +02:00
stream_interface.h MEDIUM: stream-int: introduce a new state SI_ST_RDY 2019-06-06 16:36:19 +02:00
stream.h MINOR: stream: measure and report a stream's call rate in "show sess" 2019-04-24 16:04:23 +02:00
task.h MINOR: task: introduce work lists 2019-07-12 09:07:48 +02:00
template.h
vars.h