You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
details around manticore's `body` capability, and an example of using it to query elasticsearch in a way that logstash-inputs-elasticsearch cannot (ie with aggs)
Copy file name to clipboardExpand all lines: docs/index.asciidoc
+31-1
Original file line number
Diff line number
Diff line change
@@ -62,7 +62,7 @@ output {
62
62
}
63
63
----------------------------------
64
64
65
-
Using the HTTP poller with custom a custom CA or self signed cert.
65
+
==== Using the HTTP poller with custom a custom CA or self signed cert.
66
66
67
67
If you have a self signed cert you will need to convert your server's certificate to a valid# `.jks` or `.p12` file. An easy way to do it is to run the following one-liner, substituting your server's URL for the placeholder `MYURL` and `MYPORT`.
68
68
@@ -86,6 +86,27 @@ The above snippet will create two files `downloaded_cert.pem` and `downloaded_tr
86
86
}
87
87
----------------------------------
88
88
89
+
==== Using Http_poller to query Elasticsearch
90
+
91
+
This plugin can be used to send a request body to Elasticsearch then process the response. This is especially useful for getting aggregation results.
body => '{"aggs":{"1":{"avg":{"field":"system.cpu.total.pct"}}},"size":0,"query":{"bool":{"must":[{"range":{"@timestamp":{"gte":"now-10m/m","lte":"now/m"}}}]}}}'
100
+
method => post
101
+
headers => {
102
+
"Content-Type" => "application/json"
103
+
}
104
+
}
105
+
}
106
+
schedule => { every => "10m" }
107
+
}
108
+
----------------------------------
109
+
89
110
90
111
[id="plugins-{type}s-{plugin}-options"]
91
112
==== Http_poller Input Configuration Options
@@ -98,6 +119,7 @@ This plugin supports the following configuration options plus the <<plugins-{typ
0 commit comments