Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

config_format: yaml: Support passing arbitrary objects to processors #8874

Merged
merged 1 commit into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions include/fluent-bit/flb_config_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <fluent-bit/flb_slist.h>
#include <fluent-bit/flb_sds.h>
#include <monkey/mk_core.h>
#include <cfl/cfl.h>

/* Configuration types */
#define FLB_CONFIG_MAP_STR 0 /* string */
Expand All @@ -47,6 +48,8 @@
#define FLB_CONFIG_MAP_SLIST_3 43 /* split up to 3 nodes + remaining data */
#define FLB_CONFIG_MAP_SLIST_4 44 /* split up to 4 nodes + remaining data */

#define FLB_CONFIG_MAP_VARIANT 50 /* variant that wraps a kvlist or array */

#define FLB_CONFIG_MAP_MULT 1

struct flb_config_map_val {
Expand All @@ -57,6 +60,7 @@ struct flb_config_map_val {
size_t s_num; /* FLB_CONFIG_MAP_SIZE */
flb_sds_t str; /* FLB_CONFIG_MAP_STR */
struct mk_list *list; /* FLB_CONFIG_MAP_CLIST and FLB_CONFIG_MAP_SLIST */
struct cfl_variant *variant; /* FLB_CONFIG_MAP_VARIANT */
} val;
struct mk_list *mult;
struct mk_list _head; /* Link to list if this entry is a 'multiple' entry */
Expand Down
2 changes: 1 addition & 1 deletion include/fluent-bit/flb_processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ int flb_processor_instance_check_properties(

int flb_processor_instance_set_property(
struct flb_processor_instance *ins,
const char *k, const char *v);
const char *k, struct cfl_variant *v);

const char *flb_processor_instance_get_property(
const char *key,
Expand Down
Loading
Loading