Commit Graph

94 Commits (9b7c4dd1bf8ee21330c610e9d298e5b044143429)

Author SHA1 Message Date
Chris Goller 976f5ea709 Merge branch 'master' into feature/alert-boolean-thresholds 2017-12-04 15:00:58 -06:00
Chris Goller fc94d397e6 Update kapacitor alerts to cast to float before sending to influx 2017-12-01 11:53:28 -06:00
Chris Goller a00febc343 Add boolean thresholds for kapacitor threshold alerts 2017-12-01 08:11:04 -06:00
Chris Goller 943b6129c3 Fix kapacitor variables to escape strings 2017-11-07 16:07:21 -06:00
Chris Goller b1ad6443e5 Fix several kapacitor validation failures 2017-11-07 16:02:02 -06:00
Chris Goller f4fa08e36b Fix kapacitor task panic where error condition was not checked 2017-11-07 11:42:40 -06:00
Nathan Haugo c720f8a9cb Merge pull request #2140 from influxdata/feature/kapa-insecure
Add insecure ssl support to connect to kapacitor
2017-10-26 10:40:28 -04:00
Chris Goller 1b6724122c Add insecure ssl support to connect to kapacitor 2017-10-19 22:48:31 -05:00
Chris Goller 312e74993f Refactor queryConfig fields to kapacitor to remove loops 2017-10-17 13:48:21 -05:00
Chris Goller 8f0966e570 Update kapacitor variables to guard against invalid fields 2017-10-16 12:02:47 -05:00
Chris Goller 7b786657aa Rename queryConfig field to Value and support top/bottom 2017-10-16 10:56:12 -05:00
Chris Goller 6d6a2d4a2a WIP supporting integers/floats for influxql arguments 2017-10-11 14:45:01 -05:00
Chris Goller 3c1b09704e Refactor query config field arguments to be fields 2017-10-10 18:04:45 -05:00
Chris Goller 3ba1a4c94d Refactor queryConfig to have field aliases and function arguments 2017-10-10 17:01:50 -05:00
Chris Goller 153028a830 Update Kapacitor rule POST/PUT to allow raw tickscripts without
queryConfig
2017-09-09 10:19:52 -05:00
Chris Goller 35248b8044 Update kapacitor AlertRule to containe most Kapacitor Task information 2017-09-09 10:19:52 -05:00
Chris Goller d1007513cd Update kapacitor rule response with dbrps, various dates, error, and executing. 2017-09-09 10:19:52 -05:00
Chris Goller 577403f16e Update kapacitor client tests to use Task scheme 2017-09-09 10:19:52 -05:00
Chris Goller bebe0f364a WIP 2017-09-09 10:19:52 -05:00
Chris Goller 86366741fd WIP 2017-09-09 10:19:52 -05:00
Tim Raymond 1d75235fe1 Explain magic number, var renaming
This extracts a constant and comments it for clarity. Also renames a
confusing waitgroup
2017-08-23 16:32:00 -04:00
Tim Raymond 8ae3dc35cc Extract option generator and task fetcher
The option generator goroutine and the task fetcher goroutine are more
readable when extracted into another method. Also, added some commenting
documenting what their expectations are
2017-08-23 16:21:13 -04:00
Tim Raymond fe57d1e0c7 Improve benchmark, fix offset bug
This ensures that setup time does not impact the results of the
benchmark since profiling showed that much time was spent setting up the
test array of tasks. This also uses `make` to build that slice instead.

Also, the tests revealed that there was a bug where offsets were
pre-incremented rather than post-incremented, omitting the first 100
results.
2017-08-22 10:23:24 -04:00
Tim Raymond 0d2991d719 Perf: improve performance of ListTasks
This fetches ListTasks results using a few worker goroutines to improve
performance with large numbers of tasks.
2017-08-21 17:10:13 -04:00
Tim Raymond f7291550c0 Fix issue where offset & limit won't work
Because we were testing the mock client, and not the paginating
kapacitor client for the case where limit and offset were provided, an
issue with that code path was not exposed.

The issues exposed were that the condition was incorrect for triggering
this behavior, and no return clause was present to prevent the remainder
of the ListTasks method from running.
2017-08-18 17:07:00 -04:00
Tim Raymond 4bfd982a23 Update comment
Variable name changed. Improved clarity.
2017-08-18 16:44:04 -04:00
Tim Raymond 9b71477509 Switch KapacitorRulesGet to use Pagination
Kapacitor responses are paginated, and sometimes users have more than
the default 100 tasks that are returned from Kapacitor. This replaces
the previous Kapa client with one that automatically follows paginated
responses from Kapacitor's ListTasks endpoint and returns the full
response.

Tests for the KapacitorRulesGet endpoint had to be updated because they
did not account for "limit" and "offset", and so led to an infinite
loop with the paginated client. A correct kapacitor backend will not
have this behavior
2017-08-15 17:30:29 -04:00
Tim Raymond fcf325bbbe Add PaginatingKapacitorClient
The kapacitor client used in the kapacitor endpoints is limited to
fetching whatever limit you provide it. If you provide no limit, it
defaults to a limit of 100. We use this default behavior currently.

Some users have more than 100 tasks, so we need a client that's capable
of continually fetching tasks from Kapacitor until there are none left,
and returning the full response to the frontend.

This introduces a PaginatingKapacitorClient which does exactly that.
Also, test coverage was added around the KapacitorRulesGet endpoint,
since it was previously untested.
2017-08-15 16:55:47 -04:00
Jared Scheib f6aed4ae84 Add space between functions 2017-07-21 19:57:31 -07:00
Jared Scheib d6db7ee084 Merge pull request #1724 from influxdata/feature/pushover_support-1680
Add Pushover alert support
2017-07-21 14:04:22 -07:00
Jared Scheib 62096e7561 Fix PagerDuty kapacitor node typo bug (#1751)
* Fix pagerduty kapacitor node typo bug

* Update changelog
2017-07-21 13:54:49 -07:00
Jared Scheib f1d486733d Update Kapacitor AST extract handlers to also guard against empty slices 2017-07-21 13:53:23 -07:00
Jared Scheib 1fbea1e84e Fix and remove invalid Pushover alert node keys 2017-07-20 14:59:56 -07:00
Jared Scheib 40ad225752 Extract Pushover properties for Kapa alert via AST 2017-07-17 17:30:12 -07:00
Jared Scheib ed883cffa6 Add Pushover as valid Kapacitor handler endpoint type 2017-07-17 17:29:26 -07:00
Chris Goller 4432a8227e Update kapacitor alerts and ast to 1.3.1 features. 2017-07-14 21:09:39 -05:00
Andrew Watkins e1aef32512 Add test for disabled bug 2017-06-20 11:42:19 -07:00
Andrew Watkins 8e35b84ef9 Fix enable / disable bug 2017-06-20 11:08:39 -07:00
Chris Goller 1705c6fd07 Add test coverage to kapacitor client 2017-05-25 16:04:50 -05:00
Chris Goller d19f8062ec Fix kapacitor PUT/POST returning request rather than response 2017-05-24 15:30:45 -07:00
Max Chadwick efbee30d9c Test kapacitor log extraction 2017-05-14 22:09:15 -04:00
Max Chadwick 0af4a4d47b Extract log from alerts 2017-05-14 22:01:08 -04:00
Max Chadwick 204a06e7ea Add log alert tests 2017-05-14 21:42:41 -04:00
Max Chadwick 34ad6f54d5 Add ability to log alerts 2017-05-12 22:04:38 -04:00
Chris Goller 243286892f Fix null queryConfig and add substantial test coverage to kapacitor
storage
2017-05-05 16:14:02 -05:00
Chris Goller 3821b1ccff Update Kapacitor alerts to set queryConfig to null if not parsable. 2017-05-05 14:30:20 -05:00
Andrew Watkins 92bd5d10b4 Resolve conflicts
Conflicts:
	ui/src/utils/influxql.js
2017-05-05 10:01:26 -07:00
Chris Goller 313f7e94ca Update rawtext in queryconfig to be null and not omitempty 2017-04-07 17:32:10 -05:00
Chris Goller 95d8903144 Add ID for each kapacitor rule 2017-04-05 23:19:06 -05:00
Chris Goller 46f4f43692 Update kapacitors rule's to use AST and kapacitor directly 2017-04-05 20:04:42 -05:00