]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
DEBUG: stick-tables: export stktable_add_pend_updates() for better reporting
authorWilly Tarreau <w@1wt.eu>
Wed, 10 Sep 2025 09:32:51 +0000 (11:32 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 10 Sep 2025 09:34:51 +0000 (11:34 +0200)
This function is a tasklet handler used to send peers updates, and it can
happen quite a bit in "show tasks" and "show profiling tasks", so let's
export it so that we don't face a cryptic symbol name:

  $ socat - /tmp/haproxy-n10.stat <<< "show tasks"
  Running tasks: 43 (8 threads)
    function                     places     %    lat_tot   lat_avg  calls_tot  calls_avg calls%
    process_table_expire             16   37.2   1.072m    4.021s      115831       7239   15.4
    task_process_applet              15   34.8   1.072m    4.287s      486299      32419   65.0
    stktable_add_pend_updates         8   18.6      -         -         89725      11215   12.0
    sc_conn_io_cb                     3    6.9      -         -          5007       1669    0.6
    process_peer_sync                 1    2.3   4.293s    4.293s       50765      50765    6.7

This should be backported to 3.2 as it participates to debugging the
table+peers processing overhead.

src/stick_table.c

index 5b5fdea90cea1af582c7efb224cf8d206d3e22bb..54d9699a627c2ee3b0177201a781ea027cec6d3c 100644 (file)
@@ -805,7 +805,7 @@ struct stksess *stktable_get_entry(struct stktable *table, struct stktable_key *
        return ts;
 }
 
-static struct task *stktable_add_pend_updates(struct task *t, void *ctx, unsigned int state)
+struct task *stktable_add_pend_updates(struct task *t, void *ctx, unsigned int state)
 {
        struct stktable *table = ctx;
        struct eb32_node *eb;