]> git.kaiwu.me - haproxy.git/commit
MINOR: otel: changed log-record attr to use sample expressions
authorMiroslav Zagorac <mzagorac@haproxy.com>
Fri, 3 Apr 2026 10:33:26 +0000 (12:33 +0200)
committerWilliam Lallemand <wlallemand@haproxy.com>
Mon, 13 Apr 2026 07:23:26 +0000 (09:23 +0200)
commit651e9fd8a790793d2bca201a278c199780b7d697
treeb8577b4d0607752a5d4a06122b7e8fe0c5249582
parentd96ce16cef8ae6e2c494d9c3eec332899cbc969a
MINOR: otel: changed log-record attr to use sample expressions

Replaced the static key-value attribute storage in log-record with
sample-evaluated attributes.  The 'attr' keyword now accepts a key and a
HAProxy sample expression evaluated at runtime, instead of a static string
value.

The struct (conf.h) changed from otelc_kv/attr_len to a list of
flt_otel_conf_sample entries.  The parser (parser.c) calls
flt_otel_parse_cfg_sample() with n=1 per attr keyword.  At runtime
(event.c) each attribute is evaluated via flt_otel_sample_eval() and added
via flt_otel_sample_add_kv() to a bare flt_otel_scope_data_kv, which is
passed to logger->log_span().

Updated documentation, debug macro and test configurations.
addons/otel/README
addons/otel/README-conf
addons/otel/README-configuration
addons/otel/README-implementation
addons/otel/include/conf.h
addons/otel/include/parser.h
addons/otel/src/conf.c
addons/otel/src/event.c
addons/otel/src/parser.c
addons/otel/test/full/otel.cfg
addons/otel/test/sa/otel.cfg