summaryrefslogtreecommitdiffstats
path: root/src/backends.h
diff options
context:
space:
mode:
authorLennart Weller <lhw@ring0.de>2017-07-27 09:55:55 +0000
committerLennart Weller <lhw@ring0.de>2017-07-27 09:55:55 +0000
commit1413c8953bf9ab447967fedb6246c03afa3f788e (patch)
tree9bde7ef5a8010d08c0723badb22a24bca8926834 /src/backends.h
parentRelease v. 1.6.0+dfsg-3 to Unstable (diff)
parentNew upstream version 1.7.0+dfsg (diff)
downloadnetdata-1413c8953bf9ab447967fedb6246c03afa3f788e.tar.xz
netdata-1413c8953bf9ab447967fedb6246c03afa3f788e.zip
Updated version 1.7.0+dfsg from 'upstream/1.7.0+dfsg'
with Debian dir e101ee6549c6786aab4b3f5c4f9bbb7638f17e34
Diffstat (limited to 'src/backends.h')
-rw-r--r--src/backends.h26
1 files changed, 25 insertions, 1 deletions
diff --git a/src/backends.h b/src/backends.h
index 61122a1d0..e882f3db1 100644
--- a/src/backends.h
+++ b/src/backends.h
@@ -1,6 +1,30 @@
#ifndef NETDATA_BACKENDS_H
#define NETDATA_BACKENDS_H 1
-void *backends_main(void *ptr);
+#define BACKEND_SOURCE_DATA_AS_COLLECTED 0x00000001
+#define BACKEND_SOURCE_DATA_AVERAGE 0x00000002
+#define BACKEND_SOURCE_DATA_SUM 0x00000004
+
+#define BACKEND_SOURCE_BITS (BACKEND_SOURCE_DATA_AS_COLLECTED|BACKEND_SOURCE_DATA_AVERAGE|BACKEND_SOURCE_DATA_SUM)
+
+extern int backend_send_names;
+extern int backend_update_every;
+extern uint32_t backend_options;
+extern const char *backend_prefix;
+
+extern void *backends_main(void *ptr);
+
+extern int backends_can_send_rrdset(uint32_t options, RRDSET *st);
+extern uint32_t backend_parse_data_source(const char *source, uint32_t mode);
+
+extern calculated_number backend_calculate_value_from_stored_data(
+ RRDSET *st // the chart
+ , RRDDIM *rd // the dimension
+ , time_t after // the start timestamp
+ , time_t before // the end timestamp
+ , uint32_t options // BACKEND_SOURCE_* bitmap
+ , time_t *first_timestamp // the timestamp of the first point used in this response
+ , time_t *last_timestamp // the timestamp that should be reported to backend
+);
#endif /* NETDATA_BACKENDS_H */