projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
write_kafka: do not call depreciated functions unless necessary
[collectd.git]
/
src
/
write_kafka.c
diff --git
a/src/write_kafka.c
b/src/write_kafka.c
index
a5371d4
..
2c3296d
100644
(file)
--- a/
src/write_kafka.c
+++ b/
src/write_kafka.c
@@
-114,7
+114,8
@@
static int kafka_handle(struct kafka_topic_context *ctx) /* {{{ */
INFO ("write_kafka plugin: created KAFKA handle : %s", rd_kafka_name(ctx->kafka));
INFO ("write_kafka plugin: created KAFKA handle : %s", rd_kafka_name(ctx->kafka));
-#ifdef HAVE_LIBRDKAFKA_LOGGER
+#if defined(HAVE_LIBRDKAFKA_LOGGER) && !defined(HAVE_LIBRDKAFKA_LOG_CB)
+ if
rd_kafka_set_logger(ctx->kafka, kafka_log);
#endif
}
rd_kafka_set_logger(ctx->kafka, kafka_log);
#endif
}
@@
-469,4
+470,3
@@
void module_register(void)
{
plugin_register_complex_config ("write_kafka", kafka_config);
}
{
plugin_register_complex_config ("write_kafka", kafka_config);
}
-