pulumi-newrelic 5.20.0a1709365820__py3-none-any.whl → 5.21.0a1710157101__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pulumi_newrelic/__init__.py +10 -0
- pulumi_newrelic/account_management.py +6 -2
- pulumi_newrelic/alert_channel.py +34 -2
- pulumi_newrelic/alert_condition.py +26 -2
- pulumi_newrelic/alert_muting_rule.py +6 -2
- pulumi_newrelic/alert_policy.py +48 -4
- pulumi_newrelic/alert_policy_channel.py +8 -4
- pulumi_newrelic/api_access_key.py +6 -26
- pulumi_newrelic/browser_application.py +6 -2
- pulumi_newrelic/cloud/aws_govcloud_integrations.py +2 -2
- pulumi_newrelic/cloud/aws_govcloud_link_account.py +6 -2
- pulumi_newrelic/cloud/aws_integrations.py +6 -2
- pulumi_newrelic/cloud/aws_link_account.py +6 -2
- pulumi_newrelic/cloud/azure_integrations.py +6 -2
- pulumi_newrelic/cloud/azure_link_account.py +6 -2
- pulumi_newrelic/cloud/gcp_integrations.py +6 -2
- pulumi_newrelic/cloud/gcp_link_account.py +6 -2
- pulumi_newrelic/data_partition_rule.py +8 -2
- pulumi_newrelic/entity_tags.py +8 -4
- pulumi_newrelic/events_to_metrics_rule.py +8 -4
- pulumi_newrelic/get_account.py +4 -0
- pulumi_newrelic/get_alert_policy.py +3 -3
- pulumi_newrelic/get_application.py +4 -0
- pulumi_newrelic/get_authentication_domain.py +4 -0
- pulumi_newrelic/get_cloud_account.py +4 -0
- pulumi_newrelic/get_entity.py +66 -4
- pulumi_newrelic/get_group.py +145 -0
- pulumi_newrelic/get_key_transaction.py +4 -0
- pulumi_newrelic/get_obfuscation_expression.py +4 -0
- pulumi_newrelic/get_service_level_alert_helper.py +12 -0
- pulumi_newrelic/get_test_grok_pattern.py +4 -0
- pulumi_newrelic/get_user.py +10 -6
- pulumi_newrelic/group.py +426 -0
- pulumi_newrelic/infra_alert_condition.py +33 -9
- pulumi_newrelic/insights/event.py +6 -0
- pulumi_newrelic/log_parsing_rule.py +12 -2
- pulumi_newrelic/monitor_downtime.py +28 -2
- pulumi_newrelic/notification_channel.py +72 -0
- pulumi_newrelic/notification_destination.py +132 -2
- pulumi_newrelic/nrql_alert_condition.py +28 -4
- pulumi_newrelic/nrql_drop_rule.py +30 -4
- pulumi_newrelic/obfuscation_expression.py +6 -2
- pulumi_newrelic/obfuscation_rule.py +6 -2
- pulumi_newrelic/one_dashboard.py +2 -2
- pulumi_newrelic/one_dashboard_json.py +2 -2
- pulumi_newrelic/one_dashboard_raw.py +6 -0
- pulumi_newrelic/plugins/application_settings.py +22 -2
- pulumi_newrelic/plugins/workload.py +112 -4
- pulumi_newrelic/service_level.py +20 -6
- pulumi_newrelic/synthetics/alert_condition.py +26 -2
- pulumi_newrelic/synthetics/broken_links_monitor.py +12 -2
- pulumi_newrelic/synthetics/cert_check_monitor.py +12 -2
- pulumi_newrelic/synthetics/get_private_location.py +8 -0
- pulumi_newrelic/synthetics/get_secure_credential.py +4 -0
- pulumi_newrelic/synthetics/monitor.py +20 -2
- pulumi_newrelic/synthetics/multi_location_alert_condition.py +12 -4
- pulumi_newrelic/synthetics/private_location.py +6 -2
- pulumi_newrelic/synthetics/script_monitor.py +20 -2
- pulumi_newrelic/synthetics/secure_credential.py +6 -2
- pulumi_newrelic/synthetics/step_monitor.py +8 -2
- pulumi_newrelic/user.py +4 -0
- pulumi_newrelic/workflow.py +22 -4
- {pulumi_newrelic-5.20.0a1709365820.dist-info → pulumi_newrelic-5.21.0a1710157101.dist-info}/METADATA +1 -1
- pulumi_newrelic-5.21.0a1710157101.dist-info/RECORD +89 -0
- pulumi_newrelic-5.20.0a1709365820.dist-info/RECORD +0 -87
- {pulumi_newrelic-5.20.0a1709365820.dist-info → pulumi_newrelic-5.21.0a1710157101.dist-info}/WHEEL +0 -0
- {pulumi_newrelic-5.20.0a1709365820.dist-info → pulumi_newrelic-5.21.0a1710157101.dist-info}/top_level.txt +0 -0
pulumi_newrelic/__init__.py
CHANGED
@@ -23,12 +23,14 @@ from .get_application import *
|
|
23
23
|
from .get_authentication_domain import *
|
24
24
|
from .get_cloud_account import *
|
25
25
|
from .get_entity import *
|
26
|
+
from .get_group import *
|
26
27
|
from .get_key_transaction import *
|
27
28
|
from .get_notification_destination import *
|
28
29
|
from .get_obfuscation_expression import *
|
29
30
|
from .get_service_level_alert_helper import *
|
30
31
|
from .get_test_grok_pattern import *
|
31
32
|
from .get_user import *
|
33
|
+
from .group import *
|
32
34
|
from .infra_alert_condition import *
|
33
35
|
from .log_parsing_rule import *
|
34
36
|
from .monitor_downtime import *
|
@@ -222,6 +224,14 @@ _utilities.register(
|
|
222
224
|
"newrelic:index/eventsToMetricsRule:EventsToMetricsRule": "EventsToMetricsRule"
|
223
225
|
}
|
224
226
|
},
|
227
|
+
{
|
228
|
+
"pkg": "newrelic",
|
229
|
+
"mod": "index/group",
|
230
|
+
"fqn": "pulumi_newrelic",
|
231
|
+
"classes": {
|
232
|
+
"newrelic:index/group:Group": "Group"
|
233
|
+
}
|
234
|
+
},
|
225
235
|
{
|
226
236
|
"pkg": "newrelic",
|
227
237
|
"mod": "index/infraAlertCondition",
|
@@ -106,18 +106,20 @@ class AccountManagement(pulumi.CustomResource):
|
|
106
106
|
## Example Usage
|
107
107
|
|
108
108
|
##### Create Account
|
109
|
+
<!--Start PulumiCodeChooser -->
|
109
110
|
```python
|
110
111
|
import pulumi
|
111
112
|
import pulumi_newrelic as newrelic
|
112
113
|
|
113
114
|
foo = newrelic.AccountManagement("foo", region="us01")
|
114
115
|
```
|
116
|
+
<!--End PulumiCodeChooser -->
|
115
117
|
|
116
118
|
## Import
|
117
119
|
|
118
120
|
Accounts can be imported using the `id`, e.g.
|
119
121
|
|
120
|
-
|
122
|
+
bash
|
121
123
|
|
122
124
|
```sh
|
123
125
|
$ pulumi import newrelic:index/accountManagement:AccountManagement foo <id>
|
@@ -142,18 +144,20 @@ class AccountManagement(pulumi.CustomResource):
|
|
142
144
|
## Example Usage
|
143
145
|
|
144
146
|
##### Create Account
|
147
|
+
<!--Start PulumiCodeChooser -->
|
145
148
|
```python
|
146
149
|
import pulumi
|
147
150
|
import pulumi_newrelic as newrelic
|
148
151
|
|
149
152
|
foo = newrelic.AccountManagement("foo", region="us01")
|
150
153
|
```
|
154
|
+
<!--End PulumiCodeChooser -->
|
151
155
|
|
152
156
|
## Import
|
153
157
|
|
154
158
|
Accounts can be imported using the `id`, e.g.
|
155
159
|
|
156
|
-
|
160
|
+
bash
|
157
161
|
|
158
162
|
```sh
|
159
163
|
$ pulumi import newrelic:index/accountManagement:AccountManagement foo <id>
|
pulumi_newrelic/alert_channel.py
CHANGED
@@ -172,7 +172,9 @@ class AlertChannel(pulumi.CustomResource):
|
|
172
172
|
> **WARNING:** The `AlertChannel` resource is deprecated and will be removed in the next major release. For managing channel resources in Workflows, use `NotificationChannel`.
|
173
173
|
|
174
174
|
## Example Usage
|
175
|
+
|
175
176
|
### Email
|
177
|
+
<!--Start PulumiCodeChooser -->
|
176
178
|
```python
|
177
179
|
import pulumi
|
178
180
|
import pulumi_newrelic as newrelic
|
@@ -184,9 +186,12 @@ class AlertChannel(pulumi.CustomResource):
|
|
184
186
|
),
|
185
187
|
type="email")
|
186
188
|
```
|
189
|
+
<!--End PulumiCodeChooser -->
|
190
|
+
|
187
191
|
## Additional Examples
|
188
192
|
|
189
193
|
##### Slack
|
194
|
+
<!--Start PulumiCodeChooser -->
|
190
195
|
```python
|
191
196
|
import pulumi
|
192
197
|
import pulumi_newrelic as newrelic
|
@@ -198,10 +203,12 @@ class AlertChannel(pulumi.CustomResource):
|
|
198
203
|
),
|
199
204
|
type="slack")
|
200
205
|
```
|
206
|
+
<!--End PulumiCodeChooser -->
|
201
207
|
|
202
208
|
> **NOTE:** For instructions on setting up Webhooks with Slack, please visit the article linked under the argument `slack` in the aforementioned configuration, or [this article](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-notifications/notification-channels-control-where-send-alerts/#slack) in New Relic's docs for additional details on setting up the `New Relic Alerts` Slack application, and subsequently using the generated Webhook URL.
|
203
209
|
|
204
210
|
### OpsGenie
|
211
|
+
<!--Start PulumiCodeChooser -->
|
205
212
|
```python
|
206
213
|
import pulumi
|
207
214
|
import pulumi_newrelic as newrelic
|
@@ -215,8 +222,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
215
222
|
),
|
216
223
|
type="opsgenie")
|
217
224
|
```
|
225
|
+
<!--End PulumiCodeChooser -->
|
218
226
|
|
219
227
|
### PagerDuty
|
228
|
+
<!--Start PulumiCodeChooser -->
|
220
229
|
```python
|
221
230
|
import pulumi
|
222
231
|
import pulumi_newrelic as newrelic
|
@@ -227,8 +236,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
227
236
|
),
|
228
237
|
type="pagerduty")
|
229
238
|
```
|
239
|
+
<!--End PulumiCodeChooser -->
|
230
240
|
|
231
241
|
### VictorOps
|
242
|
+
<!--Start PulumiCodeChooser -->
|
232
243
|
```python
|
233
244
|
import pulumi
|
234
245
|
import pulumi_newrelic as newrelic
|
@@ -240,8 +251,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
240
251
|
),
|
241
252
|
type="victorops")
|
242
253
|
```
|
254
|
+
<!--End PulumiCodeChooser -->
|
243
255
|
|
244
256
|
### Webhook
|
257
|
+
<!--Start PulumiCodeChooser -->
|
245
258
|
```python
|
246
259
|
import pulumi
|
247
260
|
import pulumi_newrelic as newrelic
|
@@ -261,8 +274,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
261
274
|
},
|
262
275
|
))
|
263
276
|
```
|
277
|
+
<!--End PulumiCodeChooser -->
|
264
278
|
|
265
279
|
### Webhook with complex payload
|
280
|
+
<!--Start PulumiCodeChooser -->
|
266
281
|
```python
|
267
282
|
import pulumi
|
268
283
|
import pulumi_newrelic as newrelic
|
@@ -282,12 +297,13 @@ class AlertChannel(pulumi.CustomResource):
|
|
282
297
|
),
|
283
298
|
type="webhook")
|
284
299
|
```
|
300
|
+
<!--End PulumiCodeChooser -->
|
285
301
|
|
286
302
|
## Import
|
287
303
|
|
288
304
|
Alert channels can be imported using the `id`, e.g.
|
289
305
|
|
290
|
-
|
306
|
+
bash
|
291
307
|
|
292
308
|
```sh
|
293
309
|
$ pulumi import newrelic:index/alertChannel:AlertChannel main <id>
|
@@ -312,7 +328,9 @@ class AlertChannel(pulumi.CustomResource):
|
|
312
328
|
> **WARNING:** The `AlertChannel` resource is deprecated and will be removed in the next major release. For managing channel resources in Workflows, use `NotificationChannel`.
|
313
329
|
|
314
330
|
## Example Usage
|
331
|
+
|
315
332
|
### Email
|
333
|
+
<!--Start PulumiCodeChooser -->
|
316
334
|
```python
|
317
335
|
import pulumi
|
318
336
|
import pulumi_newrelic as newrelic
|
@@ -324,9 +342,12 @@ class AlertChannel(pulumi.CustomResource):
|
|
324
342
|
),
|
325
343
|
type="email")
|
326
344
|
```
|
345
|
+
<!--End PulumiCodeChooser -->
|
346
|
+
|
327
347
|
## Additional Examples
|
328
348
|
|
329
349
|
##### Slack
|
350
|
+
<!--Start PulumiCodeChooser -->
|
330
351
|
```python
|
331
352
|
import pulumi
|
332
353
|
import pulumi_newrelic as newrelic
|
@@ -338,10 +359,12 @@ class AlertChannel(pulumi.CustomResource):
|
|
338
359
|
),
|
339
360
|
type="slack")
|
340
361
|
```
|
362
|
+
<!--End PulumiCodeChooser -->
|
341
363
|
|
342
364
|
> **NOTE:** For instructions on setting up Webhooks with Slack, please visit the article linked under the argument `slack` in the aforementioned configuration, or [this article](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-notifications/notification-channels-control-where-send-alerts/#slack) in New Relic's docs for additional details on setting up the `New Relic Alerts` Slack application, and subsequently using the generated Webhook URL.
|
343
365
|
|
344
366
|
### OpsGenie
|
367
|
+
<!--Start PulumiCodeChooser -->
|
345
368
|
```python
|
346
369
|
import pulumi
|
347
370
|
import pulumi_newrelic as newrelic
|
@@ -355,8 +378,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
355
378
|
),
|
356
379
|
type="opsgenie")
|
357
380
|
```
|
381
|
+
<!--End PulumiCodeChooser -->
|
358
382
|
|
359
383
|
### PagerDuty
|
384
|
+
<!--Start PulumiCodeChooser -->
|
360
385
|
```python
|
361
386
|
import pulumi
|
362
387
|
import pulumi_newrelic as newrelic
|
@@ -367,8 +392,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
367
392
|
),
|
368
393
|
type="pagerduty")
|
369
394
|
```
|
395
|
+
<!--End PulumiCodeChooser -->
|
370
396
|
|
371
397
|
### VictorOps
|
398
|
+
<!--Start PulumiCodeChooser -->
|
372
399
|
```python
|
373
400
|
import pulumi
|
374
401
|
import pulumi_newrelic as newrelic
|
@@ -380,8 +407,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
380
407
|
),
|
381
408
|
type="victorops")
|
382
409
|
```
|
410
|
+
<!--End PulumiCodeChooser -->
|
383
411
|
|
384
412
|
### Webhook
|
413
|
+
<!--Start PulumiCodeChooser -->
|
385
414
|
```python
|
386
415
|
import pulumi
|
387
416
|
import pulumi_newrelic as newrelic
|
@@ -401,8 +430,10 @@ class AlertChannel(pulumi.CustomResource):
|
|
401
430
|
},
|
402
431
|
))
|
403
432
|
```
|
433
|
+
<!--End PulumiCodeChooser -->
|
404
434
|
|
405
435
|
### Webhook with complex payload
|
436
|
+
<!--Start PulumiCodeChooser -->
|
406
437
|
```python
|
407
438
|
import pulumi
|
408
439
|
import pulumi_newrelic as newrelic
|
@@ -422,12 +453,13 @@ class AlertChannel(pulumi.CustomResource):
|
|
422
453
|
),
|
423
454
|
type="webhook")
|
424
455
|
```
|
456
|
+
<!--End PulumiCodeChooser -->
|
425
457
|
|
426
458
|
## Import
|
427
459
|
|
428
460
|
Alert channels can be imported using the `id`, e.g.
|
429
461
|
|
430
|
-
|
462
|
+
bash
|
431
463
|
|
432
464
|
```sh
|
433
465
|
$ pulumi import newrelic:index/alertChannel:AlertChannel main <id>
|
@@ -46,9 +46,11 @@ class AlertConditionArgs:
|
|
46
46
|
|
47
47
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
48
48
|
|
49
|
+
<!--Start PulumiCodeChooser -->
|
49
50
|
```python
|
50
51
|
import pulumi
|
51
52
|
```
|
53
|
+
<!--End PulumiCodeChooser -->
|
52
54
|
:param pulumi.Input[int] violation_close_timer: Automatically close instance-based incidents, including JVM health metric incidents, after the number of hours specified. Must be between 1 and 720 hours. Must be specified in the following two cases, to prevent drift:
|
53
55
|
* when `type` = `apm_app_metric` and `condition_scope` = `instance`
|
54
56
|
* when `type` = `apm_jvm_metric`
|
@@ -215,9 +217,11 @@ class AlertConditionArgs:
|
|
215
217
|
|
216
218
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
217
219
|
|
220
|
+
<!--Start PulumiCodeChooser -->
|
218
221
|
```python
|
219
222
|
import pulumi
|
220
223
|
```
|
224
|
+
<!--End PulumiCodeChooser -->
|
221
225
|
"""
|
222
226
|
return pulumi.get(self, "user_defined_value_function")
|
223
227
|
|
@@ -275,9 +279,11 @@ class _AlertConditionState:
|
|
275
279
|
|
276
280
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
277
281
|
|
282
|
+
<!--Start PulumiCodeChooser -->
|
278
283
|
```python
|
279
284
|
import pulumi
|
280
285
|
```
|
286
|
+
<!--End PulumiCodeChooser -->
|
281
287
|
:param pulumi.Input[int] violation_close_timer: Automatically close instance-based incidents, including JVM health metric incidents, after the number of hours specified. Must be between 1 and 720 hours. Must be specified in the following two cases, to prevent drift:
|
282
288
|
* when `type` = `apm_app_metric` and `condition_scope` = `instance`
|
283
289
|
* when `type` = `apm_jvm_metric`
|
@@ -463,9 +469,11 @@ class _AlertConditionState:
|
|
463
469
|
|
464
470
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
465
471
|
|
472
|
+
<!--Start PulumiCodeChooser -->
|
466
473
|
```python
|
467
474
|
import pulumi
|
468
475
|
```
|
476
|
+
<!--End PulumiCodeChooser -->
|
469
477
|
"""
|
470
478
|
return pulumi.get(self, "user_defined_value_function")
|
471
479
|
|
@@ -514,6 +522,7 @@ class AlertCondition(pulumi.CustomResource):
|
|
514
522
|
|
515
523
|
## Example Usage
|
516
524
|
|
525
|
+
<!--Start PulumiCodeChooser -->
|
517
526
|
```python
|
518
527
|
import pulumi
|
519
528
|
import pulumi_newrelic as newrelic
|
@@ -537,6 +546,8 @@ class AlertCondition(pulumi.CustomResource):
|
|
537
546
|
time_function="all",
|
538
547
|
)])
|
539
548
|
```
|
549
|
+
<!--End PulumiCodeChooser -->
|
550
|
+
|
540
551
|
## Terms
|
541
552
|
|
542
553
|
The `term` mapping supports the following arguments:
|
@@ -551,6 +562,7 @@ class AlertCondition(pulumi.CustomResource):
|
|
551
562
|
|
552
563
|
Manage alert condition tags with `EntityTags`. For up-to-date documentation about the tagging resource, please check EntityTags
|
553
564
|
|
565
|
+
<!--Start PulumiCodeChooser -->
|
554
566
|
```python
|
555
567
|
import pulumi
|
556
568
|
import pulumi_newrelic as newrelic
|
@@ -587,13 +599,14 @@ class AlertCondition(pulumi.CustomResource):
|
|
587
599
|
),
|
588
600
|
])
|
589
601
|
```
|
602
|
+
<!--End PulumiCodeChooser -->
|
590
603
|
|
591
604
|
## Import
|
592
605
|
|
593
606
|
Alert conditions can be imported using notation `alert_policy_id:alert_condition_id`, e.g.
|
594
607
|
|
595
608
|
```sh
|
596
|
-
|
609
|
+
$ pulumi import newrelic:index/alertCondition:AlertCondition main 123456:6789012345
|
597
610
|
```
|
598
611
|
|
599
612
|
:param str resource_name: The name of the resource.
|
@@ -613,9 +626,11 @@ class AlertCondition(pulumi.CustomResource):
|
|
613
626
|
|
614
627
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
615
628
|
|
629
|
+
<!--Start PulumiCodeChooser -->
|
616
630
|
```python
|
617
631
|
import pulumi
|
618
632
|
```
|
633
|
+
<!--End PulumiCodeChooser -->
|
619
634
|
:param pulumi.Input[int] violation_close_timer: Automatically close instance-based incidents, including JVM health metric incidents, after the number of hours specified. Must be between 1 and 720 hours. Must be specified in the following two cases, to prevent drift:
|
620
635
|
* when `type` = `apm_app_metric` and `condition_scope` = `instance`
|
621
636
|
* when `type` = `apm_jvm_metric`
|
@@ -633,6 +648,7 @@ class AlertCondition(pulumi.CustomResource):
|
|
633
648
|
|
634
649
|
## Example Usage
|
635
650
|
|
651
|
+
<!--Start PulumiCodeChooser -->
|
636
652
|
```python
|
637
653
|
import pulumi
|
638
654
|
import pulumi_newrelic as newrelic
|
@@ -656,6 +672,8 @@ class AlertCondition(pulumi.CustomResource):
|
|
656
672
|
time_function="all",
|
657
673
|
)])
|
658
674
|
```
|
675
|
+
<!--End PulumiCodeChooser -->
|
676
|
+
|
659
677
|
## Terms
|
660
678
|
|
661
679
|
The `term` mapping supports the following arguments:
|
@@ -670,6 +688,7 @@ class AlertCondition(pulumi.CustomResource):
|
|
670
688
|
|
671
689
|
Manage alert condition tags with `EntityTags`. For up-to-date documentation about the tagging resource, please check EntityTags
|
672
690
|
|
691
|
+
<!--Start PulumiCodeChooser -->
|
673
692
|
```python
|
674
693
|
import pulumi
|
675
694
|
import pulumi_newrelic as newrelic
|
@@ -706,13 +725,14 @@ class AlertCondition(pulumi.CustomResource):
|
|
706
725
|
),
|
707
726
|
])
|
708
727
|
```
|
728
|
+
<!--End PulumiCodeChooser -->
|
709
729
|
|
710
730
|
## Import
|
711
731
|
|
712
732
|
Alert conditions can be imported using notation `alert_policy_id:alert_condition_id`, e.g.
|
713
733
|
|
714
734
|
```sh
|
715
|
-
|
735
|
+
$ pulumi import newrelic:index/alertCondition:AlertCondition main 123456:6789012345
|
716
736
|
```
|
717
737
|
|
718
738
|
:param str resource_name: The name of the resource.
|
@@ -823,9 +843,11 @@ class AlertCondition(pulumi.CustomResource):
|
|
823
843
|
|
824
844
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
825
845
|
|
846
|
+
<!--Start PulumiCodeChooser -->
|
826
847
|
```python
|
827
848
|
import pulumi
|
828
849
|
```
|
850
|
+
<!--End PulumiCodeChooser -->
|
829
851
|
:param pulumi.Input[int] violation_close_timer: Automatically close instance-based incidents, including JVM health metric incidents, after the number of hours specified. Must be between 1 and 720 hours. Must be specified in the following two cases, to prevent drift:
|
830
852
|
* when `type` = `apm_app_metric` and `condition_scope` = `instance`
|
831
853
|
* when `type` = `apm_jvm_metric`
|
@@ -954,9 +976,11 @@ class AlertCondition(pulumi.CustomResource):
|
|
954
976
|
|
955
977
|
> **NOTE:** The `user_defined_value_function` can have `rate` or `percent` only when the `type` is `mobile_metric`.
|
956
978
|
|
979
|
+
<!--Start PulumiCodeChooser -->
|
957
980
|
```python
|
958
981
|
import pulumi
|
959
982
|
```
|
983
|
+
<!--End PulumiCodeChooser -->
|
960
984
|
"""
|
961
985
|
return pulumi.get(self, "user_defined_value_function")
|
962
986
|
|
@@ -234,6 +234,7 @@ class AlertMutingRule(pulumi.CustomResource):
|
|
234
234
|
"""
|
235
235
|
## Example Usage
|
236
236
|
|
237
|
+
<!--Start PulumiCodeChooser -->
|
237
238
|
```python
|
238
239
|
import pulumi
|
239
240
|
import pulumi_newrelic as newrelic
|
@@ -269,13 +270,14 @@ class AlertMutingRule(pulumi.CustomResource):
|
|
269
270
|
],
|
270
271
|
))
|
271
272
|
```
|
273
|
+
<!--End PulumiCodeChooser -->
|
272
274
|
|
273
275
|
## Import
|
274
276
|
|
275
277
|
Alert conditions can be imported using a composite ID of `<account_id>:<muting_rule_id>`, e.g.
|
276
278
|
|
277
279
|
```sh
|
278
|
-
|
280
|
+
$ pulumi import newrelic:index/alertMutingRule:AlertMutingRule foo 538291:6789035
|
279
281
|
```
|
280
282
|
|
281
283
|
:param str resource_name: The name of the resource.
|
@@ -296,6 +298,7 @@ class AlertMutingRule(pulumi.CustomResource):
|
|
296
298
|
"""
|
297
299
|
## Example Usage
|
298
300
|
|
301
|
+
<!--Start PulumiCodeChooser -->
|
299
302
|
```python
|
300
303
|
import pulumi
|
301
304
|
import pulumi_newrelic as newrelic
|
@@ -331,13 +334,14 @@ class AlertMutingRule(pulumi.CustomResource):
|
|
331
334
|
],
|
332
335
|
))
|
333
336
|
```
|
337
|
+
<!--End PulumiCodeChooser -->
|
334
338
|
|
335
339
|
## Import
|
336
340
|
|
337
341
|
Alert conditions can be imported using a composite ID of `<account_id>:<muting_rule_id>`, e.g.
|
338
342
|
|
339
343
|
```sh
|
340
|
-
|
344
|
+
$ pulumi import newrelic:index/alertMutingRule:AlertMutingRule foo 538291:6789035
|
341
345
|
```
|
342
346
|
|
343
347
|
:param str resource_name: The name of the resource.
|
pulumi_newrelic/alert_policy.py
CHANGED
@@ -181,16 +181,34 @@ class AlertPolicy(pulumi.CustomResource):
|
|
181
181
|
Use this resource to create and manage New Relic alert policies.
|
182
182
|
|
183
183
|
## Example Usage
|
184
|
+
|
184
185
|
### Basic Usage
|
185
186
|
|
187
|
+
<!--Start PulumiCodeChooser -->
|
186
188
|
```python
|
187
189
|
import pulumi
|
188
190
|
import pulumi_newrelic as newrelic
|
189
191
|
|
190
192
|
foo = newrelic.AlertPolicy("foo", incident_preference="PER_POLICY")
|
191
193
|
```
|
194
|
+
<!--End PulumiCodeChooser -->
|
195
|
+
|
192
196
|
### Provision multiple notification channels and add those channels to a policy
|
193
197
|
|
198
|
+
The following arguments are supported:
|
199
|
+
|
200
|
+
* `name` - (Required) The name of the policy.
|
201
|
+
* `incident_preference` - (Optional) The rollup strategy for the policy, which can have one of the following values (the default value is `PER_POLICY`):
|
202
|
+
* `PER_POLICY` - This sets the incident grouping preference of the policy to **One issue per policy**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-policy) for more details on this incident grouping preference.
|
203
|
+
* `PER_CONDITION` - This sets the incident grouping preference of the policy to **One issue per condition**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-condition) for more details on this incident grouping preference.
|
204
|
+
* `PER_CONDITION_AND_TARGET` - This sets the incident grouping preference of the policy to **One issue per condition and signal**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-signal) for more details on this incident grouping preference.
|
205
|
+
* `channel_ids` - (Optional) **DEPRECATED** The `channel_ids` argument is deprecated and will be removed in the next major release of the provider. An array of channel IDs (integers) to assign to the policy. Adding or removing channel IDs from this array will result in a new alert policy resource being created and the old one being destroyed. Also note that channel IDs _cannot_ be imported via `pulumi import` (see Import for info).
|
206
|
+
* `account_id` - (Optional) The New Relic account ID to operate on. This allows the user to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
207
|
+
|
208
|
+
## Additional Examples
|
209
|
+
|
210
|
+
##### Provision multiple notification channels and add those channels to a policy
|
211
|
+
<!--Start PulumiCodeChooser -->
|
194
212
|
```python
|
195
213
|
import pulumi
|
196
214
|
import pulumi_newrelic as newrelic
|
@@ -217,7 +235,10 @@ class AlertPolicy(pulumi.CustomResource):
|
|
217
235
|
email_channel.id,
|
218
236
|
])
|
219
237
|
```
|
238
|
+
<!--End PulumiCodeChooser -->
|
239
|
+
|
220
240
|
### Reference existing notification channels and add those channel to a policy
|
241
|
+
<!--Start PulumiCodeChooser -->
|
221
242
|
```python
|
222
243
|
import pulumi
|
223
244
|
import pulumi_newrelic as newrelic
|
@@ -232,6 +253,7 @@ class AlertPolicy(pulumi.CustomResource):
|
|
232
253
|
email_channel.id,
|
233
254
|
])
|
234
255
|
```
|
256
|
+
<!--End PulumiCodeChooser -->
|
235
257
|
|
236
258
|
## Import
|
237
259
|
|
@@ -240,9 +262,9 @@ class AlertPolicy(pulumi.CustomResource):
|
|
240
262
|
Example import:
|
241
263
|
|
242
264
|
```sh
|
243
|
-
|
265
|
+
$ pulumi import newrelic:index/alertPolicy:AlertPolicy foo 23423556:4593020
|
244
266
|
```
|
245
|
-
|
267
|
+
Please note that channel IDs (`channel_ids`) _cannot_ be imported due channels being a separate resource. However, to add channels to an imported alert policy, you can import the policy, add the `channel_ids` attribute with the associated channel IDs, then run `pulumi up`. This will result in the original alert policy being destroyed and a new alert policy being created along with the channels being added to the policy.
|
246
268
|
|
247
269
|
:param str resource_name: The name of the resource.
|
248
270
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
@@ -261,16 +283,34 @@ class AlertPolicy(pulumi.CustomResource):
|
|
261
283
|
Use this resource to create and manage New Relic alert policies.
|
262
284
|
|
263
285
|
## Example Usage
|
286
|
+
|
264
287
|
### Basic Usage
|
265
288
|
|
289
|
+
<!--Start PulumiCodeChooser -->
|
266
290
|
```python
|
267
291
|
import pulumi
|
268
292
|
import pulumi_newrelic as newrelic
|
269
293
|
|
270
294
|
foo = newrelic.AlertPolicy("foo", incident_preference="PER_POLICY")
|
271
295
|
```
|
296
|
+
<!--End PulumiCodeChooser -->
|
297
|
+
|
272
298
|
### Provision multiple notification channels and add those channels to a policy
|
273
299
|
|
300
|
+
The following arguments are supported:
|
301
|
+
|
302
|
+
* `name` - (Required) The name of the policy.
|
303
|
+
* `incident_preference` - (Optional) The rollup strategy for the policy, which can have one of the following values (the default value is `PER_POLICY`):
|
304
|
+
* `PER_POLICY` - This sets the incident grouping preference of the policy to **One issue per policy**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-policy) for more details on this incident grouping preference.
|
305
|
+
* `PER_CONDITION` - This sets the incident grouping preference of the policy to **One issue per condition**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-condition) for more details on this incident grouping preference.
|
306
|
+
* `PER_CONDITION_AND_TARGET` - This sets the incident grouping preference of the policy to **One issue per condition and signal**. Refer to [this page](https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-policies/specify-when-alerts-create-incidents/#preference-signal) for more details on this incident grouping preference.
|
307
|
+
* `channel_ids` - (Optional) **DEPRECATED** The `channel_ids` argument is deprecated and will be removed in the next major release of the provider. An array of channel IDs (integers) to assign to the policy. Adding or removing channel IDs from this array will result in a new alert policy resource being created and the old one being destroyed. Also note that channel IDs _cannot_ be imported via `pulumi import` (see Import for info).
|
308
|
+
* `account_id` - (Optional) The New Relic account ID to operate on. This allows the user to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
309
|
+
|
310
|
+
## Additional Examples
|
311
|
+
|
312
|
+
##### Provision multiple notification channels and add those channels to a policy
|
313
|
+
<!--Start PulumiCodeChooser -->
|
274
314
|
```python
|
275
315
|
import pulumi
|
276
316
|
import pulumi_newrelic as newrelic
|
@@ -297,7 +337,10 @@ class AlertPolicy(pulumi.CustomResource):
|
|
297
337
|
email_channel.id,
|
298
338
|
])
|
299
339
|
```
|
340
|
+
<!--End PulumiCodeChooser -->
|
341
|
+
|
300
342
|
### Reference existing notification channels and add those channel to a policy
|
343
|
+
<!--Start PulumiCodeChooser -->
|
301
344
|
```python
|
302
345
|
import pulumi
|
303
346
|
import pulumi_newrelic as newrelic
|
@@ -312,6 +355,7 @@ class AlertPolicy(pulumi.CustomResource):
|
|
312
355
|
email_channel.id,
|
313
356
|
])
|
314
357
|
```
|
358
|
+
<!--End PulumiCodeChooser -->
|
315
359
|
|
316
360
|
## Import
|
317
361
|
|
@@ -320,9 +364,9 @@ class AlertPolicy(pulumi.CustomResource):
|
|
320
364
|
Example import:
|
321
365
|
|
322
366
|
```sh
|
323
|
-
|
367
|
+
$ pulumi import newrelic:index/alertPolicy:AlertPolicy foo 23423556:4593020
|
324
368
|
```
|
325
|
-
|
369
|
+
Please note that channel IDs (`channel_ids`) _cannot_ be imported due channels being a separate resource. However, to add channels to an imported alert policy, you can import the policy, add the `channel_ids` attribute with the associated channel IDs, then run `pulumi up`. This will result in the original alert policy being destroyed and a new alert policy being created along with the channels being added to the policy.
|
326
370
|
|
327
371
|
:param str resource_name: The name of the resource.
|
328
372
|
:param AlertPolicyArgs args: The arguments to use to populate this resource's properties.
|
@@ -139,6 +139,7 @@ class AlertPolicyChannel(pulumi.CustomResource):
|
|
139
139
|
|
140
140
|
The example below will apply multiple alert channels to an existing New Relic alert policy.
|
141
141
|
|
142
|
+
<!--Start PulumiCodeChooser -->
|
142
143
|
```python
|
143
144
|
import pulumi
|
144
145
|
import pulumi_newrelic as newrelic
|
@@ -167,15 +168,16 @@ class AlertPolicyChannel(pulumi.CustomResource):
|
|
167
168
|
slack_channel.id,
|
168
169
|
])
|
169
170
|
```
|
171
|
+
<!--End PulumiCodeChooser -->
|
170
172
|
|
171
173
|
## Import
|
172
174
|
|
173
175
|
Alert policy channels can be imported using the following notation: `<policyID>:<channelID>:<channelID>`, e.g.
|
174
176
|
|
175
177
|
```sh
|
176
|
-
|
178
|
+
$ pulumi import newrelic:index/alertPolicyChannel:AlertPolicyChannel foo 123456:3462754:2938324
|
177
179
|
```
|
178
|
-
|
180
|
+
When importing `newrelic_alert_policy_channel` resource, the attribute `channel_ids`* will be set in your Terraform state. You can import multiple channels as long as those channel IDs are included as part of the import ID hash.
|
179
181
|
|
180
182
|
:param str resource_name: The name of the resource.
|
181
183
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
@@ -198,6 +200,7 @@ class AlertPolicyChannel(pulumi.CustomResource):
|
|
198
200
|
|
199
201
|
The example below will apply multiple alert channels to an existing New Relic alert policy.
|
200
202
|
|
203
|
+
<!--Start PulumiCodeChooser -->
|
201
204
|
```python
|
202
205
|
import pulumi
|
203
206
|
import pulumi_newrelic as newrelic
|
@@ -226,15 +229,16 @@ class AlertPolicyChannel(pulumi.CustomResource):
|
|
226
229
|
slack_channel.id,
|
227
230
|
])
|
228
231
|
```
|
232
|
+
<!--End PulumiCodeChooser -->
|
229
233
|
|
230
234
|
## Import
|
231
235
|
|
232
236
|
Alert policy channels can be imported using the following notation: `<policyID>:<channelID>:<channelID>`, e.g.
|
233
237
|
|
234
238
|
```sh
|
235
|
-
|
239
|
+
$ pulumi import newrelic:index/alertPolicyChannel:AlertPolicyChannel foo 123456:3462754:2938324
|
236
240
|
```
|
237
|
-
|
241
|
+
When importing `newrelic_alert_policy_channel` resource, the attribute `channel_ids`* will be set in your Terraform state. You can import multiple channels as long as those channel IDs are included as part of the import ID hash.
|
238
242
|
|
239
243
|
:param str resource_name: The name of the resource.
|
240
244
|
:param AlertPolicyChannelArgs args: The arguments to use to populate this resource's properties.
|