Commit Graph

2166 Commits

Author SHA1 Message Date
Max Neverov
c39b787800
Add metrics for notification requests (#2361) (#2383)
Signed-off-by: Max Neverov <neverov.max@gmail.com>
2020-11-06 15:24:18 +01:00
PrometheusBot
3974abd0f4
Update common Prometheus files (#2411)
Signed-off-by: prombot <prometheus-team@googlegroups.com>
2020-11-06 12:28:36 +01:00
Victor Araujo
846c04e807
Make filter labels consistent with Prometheus (#2403)
* Make filter labels consistent with Prometheus

Filtering the alert out when the label is missing precludes a
possible match for an empty value. This change allows the
match to be evaluated.

Closes #2342

Signed-off-by: Victor Araujo <vear91@gmail.com>

* Add tests for matchFilterLabels in v2 api

Signed-off-by: Victor Araujo <vear91@gmail.com>
2020-11-06 11:26:32 +01:00
PrometheusBot
6e7f922d3a
Update common Prometheus files (#2401)
Signed-off-by: prombot <prometheus-team@googlegroups.com>
2020-10-28 18:09:58 +01:00
Isaac Gaskin
10ecddd9a6
docs(readme): correcting hyperlink text for RFC url (#2396)
Signed-off-by: Isaac Gaskin <igaskin@tesla.com>
2020-10-20 22:17:02 +02:00
B++
00b86d9067
setting favicon.ico dinamically (#2392)
* added favico link with relative path

Signed-off-by: jberny <f.bernardi89@gmail.com>

* re-generated assets

Signed-off-by: jberny <f.bernardi89@gmail.com>
2020-10-15 11:10:48 +02:00
Gerard Ryan
a8ed0d5850
Add some missing PagerDuty fields to docs (#2380)
These fields are all available on the PagerdutyConfig type:
59a96579cc/config/notifiers.go (L201..L203)

I took the descriptions from the PagerDuty events-api-v2 docs:
https://developer.pagerduty.com/docs/events-api-v2/overview/

Signed-off-by: Gerard Ryan <gryan@redhat.com>
2020-09-28 15:52:37 +02:00
Kevin Hellemun
dd1a8fb77b
[#2372] Move config reload metrics to Coordinator.Reload() (#2373)
* prometheus/alertmanager#2372 Move config reload metrics to Coordinator.Reload()

Signed-off-by: Kevin Hellemun <17928966+OGKevin@users.noreply.github.com>

* #2372 Minor refactoring.

Signed-off-by: Kevin Hellemun <17928966+OGKevin@users.noreply.github.com>
2020-09-28 14:43:57 +02:00
Benoît Knecht
59a96579cc
notify/pagerduty: Filter out empty images and links (#2379)
PagerDuty Event API v2 [1] requires images to have an `src` property, and links
to have an `href` property.

This commit filters out images and links that don't satisfy those conditions,
to avoid getting an HTTP 400 error in response.

This also adds flexibilty when using templates to configure images and links,
as it's now possible to omit images or links by letting the template return an
empty string for the `src` or `href` property, respectively.

[1]: https://developer.pagerduty.com/docs/events-api-v2/trigger-events/#context-properties

Signed-off-by: Benoît Knecht <bknecht@protonmail.ch>
2020-09-25 17:31:22 +02:00
PrometheusBot
1fdff6b3f9
Update common Prometheus files (#2364)
Signed-off-by: prombot <prometheus-team@googlegroups.com>
2020-09-11 18:01:12 +02:00
Julien Pivotto
470634d49f
Update common (#2353)
- Disable HTTP2: https://github.com/prometheus/common/pull/249
- Composite duration: https://github.com/prometheus/common/pull/246

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-08-25 15:48:59 +02:00
Julien Pivotto
565fb4fc00
Remove resolve timeout from the config shipped by default (#2349)
It is not needed with Prometheus and can confuse users.

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-08-25 15:46:38 +02:00
Jon Campbell
8e861c646b
Corrected Template Username Casing (#2345)
* Corrected Template Username Casing

Signed-off-by: midnightconman <midnightconman@gmail.com>

* Added assets_vfsdata

Signed-off-by: midnightconman <midnightconman@gmail.com>
2020-08-12 17:53:56 +02:00
Fahri YARDIMCI
41cd012c61
Add alert status for extended and simple output (#2324)
Signed-off-by: Fahri Yardımcı <f.yardimci06@gmail.com>
2020-07-24 15:02:58 +02:00
Julien Pivotto
7d28e5b876
Change HA exemple defaults to be more reasonable (#2325)
10s+10s does not really change.

Give 30s for group wait and 5m for group interval seems better.

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-07-24 14:59:27 +02:00
Tim Reddehase
7a4db5c7c0
do not omit "empty" booleans in yaml output (#2317)
The "empty" boolean is the false value. This means that values of false will not
be present in the YAML output. As such they won't be displayed in the config
section on the Status overview page (/#/status), which can be especially
confusing for the SMTPRequireTLS (smtp_require_tls) field of the configuration
as this one will default to true.

Signed-off-by: Tim Reddehase <tim.reddehase@new-work.se>
2020-07-24 14:58:59 +02:00
masataka
73db78741f
Add date picker to silence form views (#2262)
* add datepicker

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* fix import error

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* fix unnecessary import from DateTime package

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* fix unnecessary import utc

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* change datetime picker component

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* added datetime picker utils

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* added datetime picker utils

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* remove config

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>

* replace case expressions to Result.toMaybe

Signed-off-by: m-masataka <m.mizukoshi.wakuwaku@gmail.com>
2020-07-24 14:52:29 +02:00
Jason Cooper
277c9ed462
notify: add markdown support for wechat (#2309)
* notify: add markdown support for wechat

Signed-off-by: Jason Cooper <master@deamwork.com>

* docs: update WeChat receiver configuration document

Signed-off-by: Jason Cooper <master@deamwork.com>

* fix: check WeChat msgType, apply default if not present

Signed-off-by: Jason Cooper <master@deamwork.com>

* chore: remove unnecessary comment

Signed-off-by: Jason Cooper <master@deamwork.com>

* fix: simplify msgType process

Signed-off-by: Jason Cooper <master@deamwork.com>

* docs: wechat configs document update

Signed-off-by: Jason Cooper <master@deamwork.com>

* fix: apply error message suggestions

Signed-off-by: Jason Cooper <master@deamwork.com>

* test: add test for regex

Signed-off-by: Jason Cooper <master@deamwork.com>

* fix: wechat message safe param

Signed-off-by: Jason Cooper <master@deamwork.com>
2020-07-06 15:56:42 +02:00
Calle Pettersson
1895fde856
Update PagerDuty doc links (#2314)
PagerDuty has restructured their documentation, making links stale

Signed-off-by: Calle Pettersson <calle@cape.nu>
2020-06-28 10:58:02 +02:00
PrometheusBot
51127923f1
Update common Prometheus files (#2310)
Signed-off-by: prombot <prometheus-team@googlegroups.com>
2020-06-23 17:04:38 +02:00
Simon Pasquier
13253c8692
docs: document alert's fingerprint (#2308)
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-18 14:52:39 +02:00
Julien Pivotto
a9d4a71494
Add note about details handling for Opsgenie (#2305)
Signed-off-by: ricoberger <mail@ricoberger.de>

Co-authored-by: ricoberger <mail@ricoberger.de>
2020-06-17 23:36:32 +02:00
Julien Pivotto
3228822f06
Merge pull request #2303 from simonpasquier/merge-release-0.21
Merge release 0.21
2020-06-17 22:19:59 +02:00
Simon Pasquier
a3d98c476a Merge remote-tracking branch 'origin/release-0.21' into merge-release-0.21
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-17 16:46:08 +02:00
Julien Pivotto
a7f9fdadbe
docs: Fix dead link to visual route editor (#2298) (#2300)
Relative links are rendered relatively to the source repository, so this
link points to GitHub at the moment.

This commit changes the link to an absolute URL, bringing readers to the
Routing tree editor.

Signed-off-by: Manuel Hutter <manuel@hutter.io>

Co-authored-by: Manuel Hutter <mhutter@users.noreply.github.com>
2020-06-17 16:42:32 +02:00
Simon Pasquier
4c6c03ebfe
Cut v0.21.0 (#2297)
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-17 10:44:48 +02:00
Manuel Hutter
2747a02774
docs: Fix dead link to visual route editor (#2298)
Relative links are rendered relatively to the source repository, so this
link points to GitHub at the moment.

This commit changes the link to an absolute URL, bringing readers to the
Routing tree editor.

Signed-off-by: Manuel Hutter <manuel@hutter.io>
2020-06-16 20:05:09 +02:00
Simon Pasquier
56f09a62b2
notify: always retry with a back-off (#2290)
By default the library implementing the back-off timer stops the timer
after 15 minutes. Since the code never checked the value returned by the
ticker, notification retries were executed without delay after the 15
minutes had elapsed (e.g. for `group_interval` greater than 15m).

This change ensures that the back-off timer never expires.

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-16 09:50:35 +02:00
Simon Pasquier
073c298d32
Merge pull request #2296 from roidelapluie/merge-0.20
Merge 0.20 release
2020-06-16 08:49:28 +02:00
Julien Pivotto
339aea1859 Merge remote-tracking branch 'origin/release-0.20' 2020-06-12 19:17:36 +02:00
Julien Pivotto
2f74a34176
Release 0.21 documentation (#2294)
* Release 0.20 docs (#2292)

* Raw docs imports

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>

* Adapt for this repository

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>

* Add max alerts doc

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>

* Remove HipChat from docs

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-06-12 12:25:00 +02:00
Julien Pivotto
1cba0c7a37
Remove HipChat (#2281)
Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-06-11 15:51:10 +02:00
Julien Pivotto
e831a6af5d
Release 0.20 docs (#2292)
* Raw docs imports

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>

* Adapt for this repository

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-06-11 15:49:40 +02:00
Julien Pivotto
ad9ed22043
Ask for all versions (#2280)
As 0.21.0 will update clusters, we want to know of people have all their
AM at the same release when they open a clustering issue.

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2020-06-11 15:16:12 +02:00
vitt-bagal
ce5d523596
Add image build for s390x architecture (#2289)
* Add suport for s390x

Signed-off-by: Nayana <nthorat@us.ibm.com>

* Added s390x support to docker image

Signed-off-by: vitthalb@us.ibm.com <vitthalb@us.ibm.com>

Co-authored-by: Nayana <nthorat@us.ibm.com>
2020-06-09 16:30:55 +02:00
Bartlomiej Plotka
6d77929c30
Merge pull request #2276 from ricoberger/pass-labels-to-opsgenie-details
Propagate labels to Opsgenie details
2020-06-09 14:39:03 +01:00
ricoberger
4b59db0adc Always pass all labels to Opsgenie
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-09 13:51:46 +02:00
ricoberger
3cff6cb5b5 Add tests for Opsgenie details
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-09 09:00:52 +02:00
ricoberger
9a87f5c113 Populate details from common labels and details
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-09 07:40:04 +02:00
Simon Pasquier
4346e1a51c
Cut v0.21.0-rc.0 (#2279)
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-05 12:56:17 +02:00
ricoberger
8248c50365 Provide option to use common labels for OpsGenie details
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-05 08:07:58 +02:00
ricoberger
dcccf542f1 Adjust Opsgenie config for labels propagation
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-04 15:47:18 +02:00
Julius Volz
12da9d6570
Merge pull request #2277 from simonpasquier/bump-orb
.circleci/config.yml: bump Prometheus orb version
2020-06-04 15:24:34 +02:00
Simon Pasquier
8b7816dc9f .circleci/config.yml: bump Prometheus orb version
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-04 14:26:21 +02:00
Simon Pasquier
f7c595c168
notify: improve logs on notification errors (#2273)
* notify: improve logs on notification errors

Alertmanager can experience occasional failures when sending
notifications to an external service. If the operation succeeds after
some retry, the 'alertmanager_notifications_failed_total' metric
increases but nothing is logged (unless running with log.level=debug).
Hence an operator might receive an alert about notification failures but
wouldn't know which integration was failing.

With this change, notification failures are logged at the warning level.
To avoid log flooding, similar failures on retries aren't logged.
Additional information on the failing integration has also been added.

Signed-off-by: Simon Pasquier <spasquie@redhat.com>

* Log notify success at info level if it's a retry

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-04 10:38:48 +02:00
Julius Volz
70b5e00ffc
Allow limiting maximum number of alerts in webhook (#2274)
* Allow limiting maximum number of alerts in webhook

The webhook notifier is the only notifier that does not allow templating
on the Alertmanager side. Users who encounter occasional alert storms
(10ks of alerts going off at once for the same group) have reported
webhook receiver systems not being able to cope with the load caused by
the resulting large webhook notifier messages (the alerting rules also
contained large annotations that can't be stripped away due to lack of
templating). Reducing group size also wasn't an option, but this change
proposes to allow truncating the list of alerts sent in the webhook body
to a provided maximum length. This assumes that e.g. if a group receives
20k alerts, you really are fine only receiving 10k because you wouldn't
be able to check them all anyway.

Signed-off-by: Julius Volz <julius.volz@gmail.com>

* Change max_alerts to uint32

Signed-off-by: Julius Volz <julius.volz@gmail.com>

* Add truncatedAlerts field to webhook message

Signed-off-by: Julius Volz <julius.volz@gmail.com>

* Fix JSON struct tag

Signed-off-by: Julius Volz <julius.volz@gmail.com>
2020-06-04 10:07:33 +02:00
Simon Pasquier
9c3ee38683
.circleci/config.yml: collect test metadata (#2211)
* .circleci/config.yml: collect test metadata

Signed-off-by: Simon Pasquier <spasquie@redhat.com>

* Store frontend test results too

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-04 09:49:32 +02:00
ricoberger
117c8ba8f1 Propagate labels to Opsgenie details
Signed-off-by: ricoberger <mail@ricoberger.de>
2020-06-04 09:30:02 +02:00
Simon Pasquier
e0cc523893
api/v2: add path and method to API v2 logs (#2261)
* api/v2: add path and method to API v2 logs

When an API v2 handler logged a message, the log wouldn't include the
path and method. Since different handlers perform the same validations
(e.g. matchers for alerts and silences), it isn't easy to know which
handler was invoked (though the logged filename
+ line number provides a hint).

Signed-off-by: Simon Pasquier <spasquie@redhat.com>

* Capitalize messages + improve logs

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2020-06-02 16:13:31 +02:00
LucasBoisserie
97bd078441
Add redirect on / to routePrefix (#2235)
Signed-off-by: LucasBoisserie <lucas.boisserie@gmail.com>
2020-05-28 17:07:55 +02:00