summaryrefslogtreecommitdiffstats
path: root/exporting/opentsdb
diff options
context:
space:
mode:
Diffstat (limited to 'exporting/opentsdb')
-rw-r--r--exporting/opentsdb/README.md20
-rw-r--r--exporting/opentsdb/opentsdb.c8
2 files changed, 17 insertions, 11 deletions
diff --git a/exporting/opentsdb/README.md b/exporting/opentsdb/README.md
index c9b1ab95a..c6069f372 100644
--- a/exporting/opentsdb/README.md
+++ b/exporting/opentsdb/README.md
@@ -1,14 +1,19 @@
<!--
title: "Export metrics to OpenTSDB"
description: "Archive your Agent's metrics to an OpenTSDB database for long-term storage and further analysis."
-custom_edit_url: https://github.com/netdata/netdata/edit/master/exporting/opentsdb/README.md
-sidebar_label: OpenTSDB
+custom_edit_url: "https://github.com/netdata/netdata/edit/master/exporting/opentsdb/README.md"
+sidebar_label: "OpenTSDB"
+learn_status: "Published"
+learn_topic_type: "Tasks"
+learn_rel_path: "Setup/Exporting connectors"
+learn_autogeneration_metadata: "{'part_of_cloud': False, 'part_of_agent': True}"
-->
# Export metrics to OpenTSDB
-You can use the OpenTSDB connector for the [exporting engine](/exporting/README.md) to archive your agent's metrics to OpenTSDB
-databases for long-term storage, further analysis, or correlation with data from other sources.
+You can use the OpenTSDB connector for
+the [exporting engine](https://github.com/netdata/netdata/blob/master/exporting/README.md) to archive your agent's
+metrics to OpenTSDB databases for long-term storage, further analysis, or correlation with data from other sources.
## Configuration
@@ -21,7 +26,8 @@ directory and set the following options:
destination = localhost:4242
```
-Add `:http` or `:https` modifiers to the connector type if you need to use other than a plaintext protocol. For example: `opentsdb:http:my_opentsdb_instance`,
+Add `:http` or `:https` modifiers to the connector type if you need to use other than a plaintext protocol. For
+example: `opentsdb:http:my_opentsdb_instance`,
`opentsdb:https:my_opentsdb_instance`. You can set basic HTTP authentication credentials using
```conf
@@ -29,7 +35,7 @@ Add `:http` or `:https` modifiers to the connector type if you need to use other
password = my_password
```
-The OpenTSDB connector is further configurable using additional settings. See the [exporting reference
-doc](/exporting/README.md#options) for details.
+The OpenTSDB connector is further configurable using additional settings. See
+the [exporting reference doc](https://github.com/netdata/netdata/blob/master/exporting/README.md#options) for details.
diff --git a/exporting/opentsdb/opentsdb.c b/exporting/opentsdb/opentsdb.c
index a974c1264..fc01ae461 100644
--- a/exporting/opentsdb/opentsdb.c
+++ b/exporting/opentsdb/opentsdb.c
@@ -45,7 +45,7 @@ int init_opentsdb_telnet_instance(struct instance *instance)
instance->prepare_header = NULL;
instance->check_response = exporting_discard_response;
- instance->buffer = (void *)buffer_create(0);
+ instance->buffer = (void *)buffer_create(0, &netdata_buffers_statistics.buffers_exporters);
if (!instance->buffer) {
error("EXPORTING: cannot create buffer for opentsdb telnet exporting connector instance %s", instance->config.name);
return 1;
@@ -102,7 +102,7 @@ int init_opentsdb_http_instance(struct instance *instance)
instance->prepare_header = opentsdb_http_prepare_header;
instance->check_response = exporting_discard_response;
- instance->buffer = (void *)buffer_create(0);
+ instance->buffer = (void *)buffer_create(0, &netdata_buffers_statistics.buffers_exporters);
if (!instance->buffer) {
error("EXPORTING: cannot create buffer for opentsdb HTTP exporting connector instance %s", instance->config.name);
return 1;
@@ -150,7 +150,7 @@ void sanitize_opentsdb_label_value(char *dst, const char *src, size_t len)
int format_host_labels_opentsdb_telnet(struct instance *instance, RRDHOST *host) {
if(!instance->labels_buffer)
- instance->labels_buffer = buffer_create(1024);
+ instance->labels_buffer = buffer_create(1024, &netdata_buffers_statistics.buffers_exporters);
if (unlikely(!sending_labels_configured(instance)))
return 0;
@@ -283,7 +283,7 @@ void opentsdb_http_prepare_header(struct instance *instance)
int format_host_labels_opentsdb_http(struct instance *instance, RRDHOST *host) {
if (!instance->labels_buffer)
- instance->labels_buffer = buffer_create(1024);
+ instance->labels_buffer = buffer_create(1024, &netdata_buffers_statistics.buffers_exporters);
if (unlikely(!sending_labels_configured(instance)))
return 0;