flex
flex copied to clipboard
A simple Elixir InfluxDB client.
First of all, thank you so much for a nice example of great problem-solving. I'd like to propose a small fix for a really rare occasion. Currently, an Elixir list...
This solution worked for my case: i.e. when we kill a running MongooseIM node and then transfer metrics there's no error. Grafana correctly displays the graphs where the values are...
``` iex(4)> Flex.API.create_db("my_db", host: "http://localhost:8086") ** (BadMapError) expected a map, got: [host: "http://localhost:8086"] (elixir) lib/map.ex:667: Map.drop([host: "http://localhost:8086"], []) (flex) lib/flex/api.ex:286: Flex.API.check_params/3 (flex) lib/flex/api.ex:234: Flex.API.do_post_to_read_endpoint/4 ``` ``` iex(9)> Flex.API.get_databases(host: "http://localhost:8086") **...
When we give InfluxDB some time to response, we have to also respect it in call to GenServer. Otherwise it will timeout after default time (5s).
We may have situation like: ``` Time X Y Z 1 . nil nil 0 2 . 1 nil 0 3 . 1 nil 0 ``` So in this situation...