Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
config_format: yaml: Support passing arbitrary objects to processors
This was initially based on fluent#8656 and fluent#8661 but ended up making few different choices: - Instead of adding FLB_CONFIG_MAP_KVLIST and FLB_CONFIG_MAP_ARRAY as config map types, it adds a single FLB_CONFIG_MAP_VARIANT which accepts an array or map. The passed array/map can have nested values and accept any JSON/YAML types, which are converted to cfl types. The processor will simply receive a `cfl_variant` pointer but doesn't own it, the config section is responsible for releasing its memory. - The existing `flb_config_map_set` function is reused by passing the `cfl_variant` pointer (from the yaml parsing phase) as the value of a `flb_kv`. Then pointer is eventually passed to the processor context. Signed-off-by: Thiago Padilha <[email protected]>
- Loading branch information