kennel 1.144.0 → 1.144.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cbe42470ccefd609c694baedef17ec3ddb4fe2ac954c0a881019092a9c3537a6
4
- data.tar.gz: c395cb4abfa8d9c81673883501478d99344e68de66a0424c714c648b4b4f26f1
3
+ metadata.gz: 6d1cc43aa92bfd88e9cc7c7f33f1c91aaafc0c5a936e2c8dc0d153c20f7bfc85
4
+ data.tar.gz: e1f75c40c4c9a9d38438a2563241193172bc56e020f6ff3b3295dc8485ae415d
5
5
  SHA512:
6
- metadata.gz: c8b5b3f45ded5dc8995dcc143c6ff82c0aa64da8445a3c18edce7668b519cb0afa91e4c920f8c9820523237a785ffdbac1694f92621c1ff3137bf71c7c7b44f7
7
- data.tar.gz: 734d02fce4549ce4bb4ad15ce8d821d54fbbb042647f66a5445e26e36f5bc944538531206fbb6abe238d4ab79ed63eeeeecaea02bb0e98a55ef03254b7f637d5
6
+ metadata.gz: 1715277a99ad67ec234522351420712d3c69b617f8ca8cb05118a5d5207ff236177d08183c1315284f4219afd269051745fe6231c771bda943194b0ea2ce6724
7
+ data.tar.gz: cbf498bd57f5668806fab7142048e8e4864ebc745f094189ecc9993bd75a288dc994bac582bbc00ce2eaa704a36916066247ce9fd460d4e861733dc5df7b5843
data/Readme.md CHANGED
@@ -199,7 +199,6 @@ end
199
199
  ### Updating an existing monitor
200
200
  - use [datadog monitor UI](https://app.datadoghq.com/monitors/manage) to find a monitor
201
201
  - run `URL='https://app.datadoghq.com/monitors/123' bundle exec rake kennel:import` and copy the output
202
- - import task also works with SLO alerts, e.g. `URL='https://app.datadoghq.com/slo/edit/123abc456def123/alerts/789' bundle exec rake kennel:import`
203
202
  - find or create a project in `projects/`
204
203
  - add the monitor to `parts: [` list, for example:
205
204
  ```Ruby
@@ -4,7 +4,6 @@ module Kennel
4
4
  class Monitor < Record
5
5
  include TagsValidation
6
6
 
7
- RENOTIFY_INTERVALS = [0, 10, 20, 30, 40, 50, 60, 90, 120, 180, 240, 300, 360, 720, 1440].freeze # minutes
8
7
  OPTIONAL_SERVICE_CHECK_THRESHOLDS = [:ok, :warning].freeze
9
8
  READONLY_ATTRIBUTES = superclass::READONLY_ATTRIBUTES + [
10
9
  :multi, :matching_downtimes, :overall_state_modified, :overall_state, :restricted_roles
@@ -261,11 +260,6 @@ module Kennel
261
260
  end
262
261
  end
263
262
 
264
- # verify renotify interval is valid
265
- unless RENOTIFY_INTERVALS.include? data.dig(:options, :renotify_interval)
266
- invalid! :invalid_renotify_interval, "renotify_interval must be one of #{RENOTIFY_INTERVALS.join(", ")}"
267
- end
268
-
269
263
  if ["query alert", "service check"].include?(type) # TODO: most likely more types need this
270
264
  validate_message_variables(data)
271
265
  end
@@ -55,7 +55,7 @@ module Kennel
55
55
  end
56
56
 
57
57
  def self.parse_url(url)
58
- url[/\/slo(\?.*slo_id=|\/edit\/)([a-z\d]{10,})(&|$)/, 2]
58
+ url[/[?&]slo_id=([a-z\d]{10,})/, 1] || url[/\/slo\/([a-z\d]{10,})\/edit(\?|$)/, 1]
59
59
  end
60
60
 
61
61
  def resolve_linked_tracking_ids!(id_map, **args)
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Kennel
3
- VERSION = "1.144.0"
3
+ VERSION = "1.144.2"
4
4
  end
data/template/Readme.md CHANGED
@@ -181,7 +181,6 @@ end
181
181
  ### Updating an existing monitor
182
182
  - use [datadog monitor UI](https://app.datadoghq.com/monitors/manage) to find a monitor
183
183
  - run `URL='https://app.datadoghq.com/monitors/123' bundle exec rake kennel:import` and copy the output
184
- - import task also works with SLO alerts, e.g. `URL='https://app.datadoghq.com/slo/edit/123abc456def123/alerts/789' bundle exec rake kennel:import`
185
184
  - find or create a project in `projects/`
186
185
  - add the monitor to `parts: [` list, for example:
187
186
  ```Ruby
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kennel
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.144.0
4
+ version: 1.144.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-08-27 00:00:00.000000000 Z
11
+ date: 2023-09-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: diff-lcs