Commit Graph

66 Commits

Author SHA1 Message Date
Łukasz Mierzwa
0015d3fa4e feat(ui): replace jira link detection with a generic link finder
Fixes #1140
2019-11-11 23:24:06 +00:00
Łukasz Mierzwa
990a3de46b chore(backend): log a warning when alertmanager 0.17 or 0.18 is detected
Fixes #1099
2019-10-29 21:37:40 +00:00
Łukasz Mierzwa
8a544e6d5c fix(tests): add more dedup tests 2019-10-27 07:35:04 +00:00
Łukasz Mierzwa
22ea4393ab feat(api): expose all silences under /silences.json 2019-10-26 17:36:12 +01:00
Łukasz Mierzwa
acb6eab2ac fix(api): sort upstreams in the API response 2019-10-21 11:40:34 +01:00
Łukasz Mierzwa
1346237777 fix(project): refactor proxy & external_uri handling
Fixes #1024
2019-10-11 00:10:58 +01:00
Łukasz Mierzwa
4efe17e8f1 feat(api): expose alertmanager headers in the API 2019-09-26 20:37:23 +01:00
Łukasz Mierzwa
ad699fc6fe feat(backend): add external_uri config option for alertmanager upstreams
Fixes #899
2019-08-27 21:58:52 +01:00
Łukasz Mierzwa
77735ffcf1 fix(backend): fix problems found by new linters 2019-08-18 15:51:54 +01:00
Łukasz Mierzwa
29b6c7baae fix(backend): fix problems found by new linters 2019-08-18 10:58:26 +01:00
Łukasz Mierzwa
939970fd5f fix(backend): reformat backend code 2019-08-17 14:52:35 +01:00
Łukasz Mierzwa
6b497217d9 fix(backend): remove endsAt from alerts
This is unused but keeps changing
2019-08-08 15:45:00 +01:00
Łukasz Mierzwa
9b6273595d chore: move sorting to the backend 2019-08-08 15:45:00 +01:00
Łukasz Mierzwa
4bd9f447e2 feat(backend): query cluster status via v2 Alertmanager API
This change switches to v2 API when querying for cluster status on Alertmanager 0.17.0+.
v1 will soon be removed so this is needed to support future Alertmanager releases
2019-06-22 17:48:33 +01:00
Łukasz Mierzwa
2efa67ebd3 chore(tests): add more backend test coverage 2019-05-12 14:36:51 +01:00
Łukasz Mierzwa
5dd3b35f35 chore(backend): move metrics to the main package 2019-05-12 12:11:10 +01:00
Łukasz Mierzwa
0c94d7f5ba feat(backend): add alertmanager v0.17.0 mock files for testing
file:// scheme is not supported so we need some changes to always use mocks
2019-05-10 21:08:16 +01:00
Łukasz Mierzwa
94ddb04b93 chore(backend): rename mapper to match alertmanager version 2019-05-03 20:01:43 +01:00
Łukasz Mierzwa
dfea73923c refactor(backend): add support for OpenAPI based client for alertmanager 2019-04-24 20:56:58 +01:00
Łukasz Mierzwa
24e3c904ce fix(backend): correct the name of metric collector 2019-04-24 20:56:00 +01:00
Łukasz Mierzwa
7a0a587ddb feat(api): expose alert.inhibitedBy in the API 2019-03-05 11:00:54 +00:00
Łukasz Mierzwa
22f719adc6 fix(api): apply colors to the @alertmanager label
It's a fake label so it needs special code to inject the color information to the API response.

Fixes #421
2019-02-06 17:11:25 +00:00
Łukasz Mierzwa
b52c3f7af4 feat(backend): allow disabling TLS certificate validation
Fixes #409
2019-02-01 20:57:34 +01:00
Łukasz Mierzwa
af9e55032e feat(api): use metrics to detect Alertmanager version
We need to know upstream version to decide which API endpoints we can use, metrics don't change between versions so they allow us to do that without any prior knowlage or assumptions
2019-01-30 17:57:02 +00:00
Richard Maynard
ec14be0288 feat(backend): add support for custom headers (#368)
This will allow the AlertManager upstreams to be sent user defined HTTP headers.
2019-01-17 08:53:33 +00:00
Łukasz Mierzwa
e1f9686e3f feat(backend): allow stripping annotations
This allows same filtering we already have with labels. Fixes #312
2019-01-15 22:12:23 +00:00
Łukasz Mierzwa
0d68ea4c3c feat(api): store silences per cluster in the API response 2018-12-01 09:53:47 +00:00
Łukasz Mierzwa
93617b3b18 fix(api): ensure that cluster members are always sorted 2018-11-30 23:59:58 +00:00
Łukasz Mierzwa
76dd51bb92 feat(api): expose Alertmanager instance version and cluster members
Store and expose via API the version of each Alertmanager instance and the list of instances in the same cluster
2018-11-30 18:35:34 +00:00
Łukasz Mierzwa
c4bcc04abf fix(tests): relax ac count test
This needs a better and more explicit test, relax it for now
2018-11-10 13:08:44 +00:00
Łukasz Mierzwa
ade996a6ec refactor(api): move autocomplete code to filters 2018-10-08 23:15:28 +01:00
Łukasz Mierzwa
f03887b56c feat(api): add @silence_id filter
This allows to filter alerts by silence ID, only matches silenced alerts
2018-10-08 23:02:38 +01:00
Łukasz Mierzwa
80e7caf627 fix(ui): expose Alertmanager instance public URI in upstreams list 2018-09-11 21:03:54 +01:00
Łukasz Mierzwa
9c16ffa447 chore(project): rename from unsee to karma
Fixes prymitive/unsee#23
2018-09-09 14:12:26 +01:00
Łukasz Mierzwa
c6dc362186 fix(style): error strings should not be capitalized or end with punctuation or a newline 2018-08-11 23:03:02 +01:00
Łukasz Mierzwa
b2a0f61d4e fix(style): simplify append code 2018-08-11 22:46:34 +01:00
Łukasz Mierzwa
2ec3df93d7 fix(style): check for alertmanager.RegisterAlertmanager error return 2018-08-11 22:43:22 +01:00
Łukasz Mierzwa
b3709927f7 feat(api): add an enpoint that returns all known label values for given label name
This will be used in the silence form, to provide a list of suggestions
2018-08-10 17:36:00 +01:00
Łukasz Mierzwa
d934dbb053 feat(api): add /labelNames.json endpoint
This endpoint will be used for label name autocomplete in the silence form
2018-08-10 17:36:00 +01:00
Łukasz Mierzwa
6c7ba5551c refactor(api): move silences into a dedicated key in API response
A single silence can supress multiple alerts so to reduce response size and the amount of data react UI needs to track move it out of alert instance (which will deduplicate it) and on each alert only store a reference. In the API return all silences as a global dict and each alert only contains the ID of silences suppressing it.
2018-07-19 23:38:11 +02:00
Łukasz Mierzwa
b71883f1ef Migrate to new repo
Forked unsee from cloudflare, so import paths needs to be updated
2018-06-07 15:30:57 +02:00
Łukasz Mierzwa
fd0eb46adf Sanitize Alertmanager URI before putting it in /alerts.json reponse
Alertmanager URI might contain basic auth username & password, we should replace password with 'xxx' in logs and and error messages.
Go will still print it in HTTP request errors, but that will be fixed in the next Go release - https://go-review.googlesource.com/c/go/+/102855
Fixes #259
2018-04-27 09:36:12 -07:00
Łukasz Mierzwa
0f73b20bc6 Allow passing query args to HTTP requests send to the Alertmanager API
Alertmanager 0.4.x silences endpoint uses pagination, code for this was incorrectly dropped in #216, re-add it. Requires a way for mapper packages to signal the need for passing query args to HTTP requests
2018-01-24 19:09:02 -08:00
Łukasz Mierzwa
60b1c696a3 Too many 'T' in NewHTTTPTransport 2018-01-24 13:04:27 -08:00
Łukasz Mierzwa
a0cf3cc43c Add a JSON tag for ProxyRequests attr 2018-01-23 21:38:46 -08:00
Łukasz Mierzwa
49d1ed2e1e Pass HTTP transport to the proxy
When we proxy requests we should use same transport as we use when collecting alerts & silences
2018-01-23 21:37:56 -08:00
Łukasz Mierzwa
d5a7cb9ace Rename Transport interface to Reader 2018-01-23 19:40:24 -08:00
Łukasz Mierzwa
6f89a77f8d Rename 'transport' package to 'uri'
This package adds handlers for different URI schemes, name clashes with http.Transport which is now passed around. Rename it to make it more obvious what it does
2018-01-23 19:32:39 -08:00
Łukasz Mierzwa
338a4c38a6 Drop duplicated function
There's identical method on the Alertmanager instance that's being used
2018-01-23 19:22:50 -08:00
Łukasz Mierzwa
24335ebf1f Add support for passing path to custom TLS CA cert & client key/cert pair
This adds support for passing a custom http.RoundTripper so in effect we can customize TLS client config for HTTPS requests.
Fixes #184
2018-01-23 19:22:12 -08:00