pulumi-newrelic 5.23.0__py3-none-any.whl → 5.23.0a1711707796__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/_inputs.py +270 -183
- pulumi_newrelic/account_management.py +20 -20
- pulumi_newrelic/alert_channel.py +92 -76
- pulumi_newrelic/alert_condition.py +163 -104
- pulumi_newrelic/alert_muting_rule.py +35 -33
- pulumi_newrelic/alert_policy.py +43 -68
- pulumi_newrelic/alert_policy_channel.py +8 -12
- pulumi_newrelic/cloud/_inputs.py +1072 -322
- pulumi_newrelic/cloud/aws_govcloud_link_account.py +6 -4
- pulumi_newrelic/cloud/aws_integrations.py +15 -13
- pulumi_newrelic/cloud/aws_link_account.py +6 -4
- pulumi_newrelic/cloud/azure_integrations.py +12 -10
- pulumi_newrelic/cloud/azure_link_account.py +6 -4
- pulumi_newrelic/cloud/gcp_integrations.py +6 -6
- pulumi_newrelic/cloud/gcp_link_account.py +6 -4
- pulumi_newrelic/cloud/outputs.py +1072 -322
- pulumi_newrelic/data_partition_rule.py +4 -0
- pulumi_newrelic/entity_tags.py +17 -13
- pulumi_newrelic/events_to_metrics_rule.py +4 -2
- pulumi_newrelic/get_account.py +4 -0
- pulumi_newrelic/get_application.py +10 -8
- pulumi_newrelic/get_authentication_domain.py +8 -4
- pulumi_newrelic/get_cloud_account.py +4 -0
- pulumi_newrelic/get_entity.py +32 -28
- pulumi_newrelic/get_group.py +8 -42
- pulumi_newrelic/get_key_transaction.py +10 -8
- pulumi_newrelic/get_notification_destination.py +1 -20
- pulumi_newrelic/get_obfuscation_expression.py +4 -2
- pulumi_newrelic/get_service_level_alert_helper.py +46 -22
- pulumi_newrelic/get_test_grok_pattern.py +6 -4
- pulumi_newrelic/get_user.py +4 -0
- pulumi_newrelic/group.py +42 -40
- pulumi_newrelic/infra_alert_condition.py +145 -154
- pulumi_newrelic/insights/event.py +25 -8
- pulumi_newrelic/log_parsing_rule.py +10 -6
- pulumi_newrelic/monitor_downtime.py +193 -174
- pulumi_newrelic/notification_channel.py +150 -124
- pulumi_newrelic/notification_destination.py +1 -95
- pulumi_newrelic/nrql_alert_condition.py +48 -38
- pulumi_newrelic/nrql_drop_rule.py +38 -34
- pulumi_newrelic/obfuscation_expression.py +4 -2
- pulumi_newrelic/obfuscation_rule.py +4 -4
- pulumi_newrelic/one_dashboard.py +48 -42
- pulumi_newrelic/one_dashboard_raw.py +86 -86
- pulumi_newrelic/outputs.py +270 -180
- pulumi_newrelic/plugins/_inputs.py +16 -16
- pulumi_newrelic/plugins/application_settings.py +36 -20
- pulumi_newrelic/plugins/outputs.py +16 -16
- pulumi_newrelic/plugins/workload.py +40 -158
- pulumi_newrelic/service_level.py +123 -38
- pulumi_newrelic/synthetics/alert_condition.py +78 -34
- pulumi_newrelic/synthetics/broken_links_monitor.py +20 -18
- pulumi_newrelic/synthetics/cert_check_monitor.py +18 -16
- pulumi_newrelic/synthetics/get_private_location.py +8 -0
- pulumi_newrelic/synthetics/get_secure_credential.py +12 -0
- pulumi_newrelic/synthetics/monitor.py +52 -48
- pulumi_newrelic/synthetics/multi_location_alert_condition.py +83 -69
- pulumi_newrelic/synthetics/private_location.py +6 -6
- pulumi_newrelic/synthetics/script_monitor.py +42 -38
- pulumi_newrelic/synthetics/secure_credential.py +22 -25
- pulumi_newrelic/synthetics/step_monitor.py +20 -18
- pulumi_newrelic/user.py +10 -8
- pulumi_newrelic/workflow.py +24 -20
- {pulumi_newrelic-5.23.0.dist-info → pulumi_newrelic-5.23.0a1711707796.dist-info}/METADATA +1 -1
- pulumi_newrelic-5.23.0a1711707796.dist-info/RECORD +89 -0
- pulumi_newrelic-5.23.0.dist-info/RECORD +0 -89
- {pulumi_newrelic-5.23.0.dist-info → pulumi_newrelic-5.23.0a1711707796.dist-info}/WHEEL +0 -0
- {pulumi_newrelic-5.23.0.dist-info → pulumi_newrelic-5.23.0a1711707796.dist-info}/top_level.txt +0 -0
@@ -28,12 +28,12 @@ class WorkloadArgs:
|
|
28
28
|
The set of arguments for constructing a Workload resource.
|
29
29
|
:param pulumi.Input[int] account_id: The New Relic account ID where you want to create the workload.
|
30
30
|
:param pulumi.Input[str] description: Relevant information about the workload.
|
31
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload.
|
32
|
-
:param pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]] entity_search_queries: A list of search queries that define a dynamic workload.
|
31
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
32
|
+
:param pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]] entity_search_queries: A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
33
33
|
:param pulumi.Input[str] name: The workload's name.
|
34
34
|
:param pulumi.Input[Sequence[pulumi.Input[int]]] scope_account_ids: A list of account IDs that will be used to get entities from.
|
35
|
-
:param pulumi.Input['WorkloadStatusConfigAutomaticArgs'] status_config_automatic: An input object used to represent an automatic status configuration.
|
36
|
-
:param pulumi.Input['WorkloadStatusConfigStaticArgs'] status_config_static: A list of static status configurations. You can only configure one static status for a workload.
|
35
|
+
:param pulumi.Input['WorkloadStatusConfigAutomaticArgs'] status_config_automatic: An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
36
|
+
:param pulumi.Input['WorkloadStatusConfigStaticArgs'] status_config_static: A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
37
37
|
"""
|
38
38
|
if account_id is not None:
|
39
39
|
pulumi.set(__self__, "account_id", account_id)
|
@@ -80,7 +80,7 @@ class WorkloadArgs:
|
|
80
80
|
@pulumi.getter(name="entityGuids")
|
81
81
|
def entity_guids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
82
82
|
"""
|
83
|
-
A list of entity GUIDs manually assigned to this workload.
|
83
|
+
A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
84
84
|
"""
|
85
85
|
return pulumi.get(self, "entity_guids")
|
86
86
|
|
@@ -92,7 +92,7 @@ class WorkloadArgs:
|
|
92
92
|
@pulumi.getter(name="entitySearchQueries")
|
93
93
|
def entity_search_queries(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]]]:
|
94
94
|
"""
|
95
|
-
A list of search queries that define a dynamic workload.
|
95
|
+
A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
96
96
|
"""
|
97
97
|
return pulumi.get(self, "entity_search_queries")
|
98
98
|
|
@@ -128,7 +128,7 @@ class WorkloadArgs:
|
|
128
128
|
@pulumi.getter(name="statusConfigAutomatic")
|
129
129
|
def status_config_automatic(self) -> Optional[pulumi.Input['WorkloadStatusConfigAutomaticArgs']]:
|
130
130
|
"""
|
131
|
-
An input object used to represent an automatic status configuration.
|
131
|
+
An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
132
132
|
"""
|
133
133
|
return pulumi.get(self, "status_config_automatic")
|
134
134
|
|
@@ -140,7 +140,7 @@ class WorkloadArgs:
|
|
140
140
|
@pulumi.getter(name="statusConfigStatic")
|
141
141
|
def status_config_static(self) -> Optional[pulumi.Input['WorkloadStatusConfigStaticArgs']]:
|
142
142
|
"""
|
143
|
-
A list of static status configurations. You can only configure one static status for a workload.
|
143
|
+
A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
144
144
|
"""
|
145
145
|
return pulumi.get(self, "status_config_static")
|
146
146
|
|
@@ -169,14 +169,14 @@ class _WorkloadState:
|
|
169
169
|
:param pulumi.Input[int] account_id: The New Relic account ID where you want to create the workload.
|
170
170
|
:param pulumi.Input[str] composite_entity_search_query: The composite query used to compose a dynamic workload.
|
171
171
|
:param pulumi.Input[str] description: Relevant information about the workload.
|
172
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload.
|
173
|
-
:param pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]] entity_search_queries: A list of search queries that define a dynamic workload.
|
172
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
173
|
+
:param pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]] entity_search_queries: A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
174
174
|
:param pulumi.Input[str] guid: The unique entity identifier of the workload in New Relic.
|
175
175
|
:param pulumi.Input[str] name: The workload's name.
|
176
176
|
:param pulumi.Input[str] permalink: The URL of the workload.
|
177
177
|
:param pulumi.Input[Sequence[pulumi.Input[int]]] scope_account_ids: A list of account IDs that will be used to get entities from.
|
178
|
-
:param pulumi.Input['WorkloadStatusConfigAutomaticArgs'] status_config_automatic: An input object used to represent an automatic status configuration.
|
179
|
-
:param pulumi.Input['WorkloadStatusConfigStaticArgs'] status_config_static: A list of static status configurations. You can only configure one static status for a workload.
|
178
|
+
:param pulumi.Input['WorkloadStatusConfigAutomaticArgs'] status_config_automatic: An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
179
|
+
:param pulumi.Input['WorkloadStatusConfigStaticArgs'] status_config_static: A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
180
180
|
:param pulumi.Input[int] workload_id: The unique entity identifier of the workload.
|
181
181
|
"""
|
182
182
|
if account_id is not None:
|
@@ -244,7 +244,7 @@ class _WorkloadState:
|
|
244
244
|
@pulumi.getter(name="entityGuids")
|
245
245
|
def entity_guids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
246
246
|
"""
|
247
|
-
A list of entity GUIDs manually assigned to this workload.
|
247
|
+
A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
248
248
|
"""
|
249
249
|
return pulumi.get(self, "entity_guids")
|
250
250
|
|
@@ -256,7 +256,7 @@ class _WorkloadState:
|
|
256
256
|
@pulumi.getter(name="entitySearchQueries")
|
257
257
|
def entity_search_queries(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['WorkloadEntitySearchQueryArgs']]]]:
|
258
258
|
"""
|
259
|
-
A list of search queries that define a dynamic workload.
|
259
|
+
A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
260
260
|
"""
|
261
261
|
return pulumi.get(self, "entity_search_queries")
|
262
262
|
|
@@ -316,7 +316,7 @@ class _WorkloadState:
|
|
316
316
|
@pulumi.getter(name="statusConfigAutomatic")
|
317
317
|
def status_config_automatic(self) -> Optional[pulumi.Input['WorkloadStatusConfigAutomaticArgs']]:
|
318
318
|
"""
|
319
|
-
An input object used to represent an automatic status configuration.
|
319
|
+
An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
320
320
|
"""
|
321
321
|
return pulumi.get(self, "status_config_automatic")
|
322
322
|
|
@@ -328,7 +328,7 @@ class _WorkloadState:
|
|
328
328
|
@pulumi.getter(name="statusConfigStatic")
|
329
329
|
def status_config_static(self) -> Optional[pulumi.Input['WorkloadStatusConfigStaticArgs']]:
|
330
330
|
"""
|
331
|
-
A list of static status configurations. You can only configure one static status for a workload.
|
331
|
+
A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
332
332
|
"""
|
333
333
|
return pulumi.get(self, "status_config_static")
|
334
334
|
|
@@ -373,12 +373,12 @@ class Workload(pulumi.CustomResource):
|
|
373
373
|
## Example Usage
|
374
374
|
|
375
375
|
Include entities with a certain string on the name.
|
376
|
+
<!--Start PulumiCodeChooser -->
|
376
377
|
```python
|
377
378
|
import pulumi
|
378
379
|
import pulumi_newrelic as newrelic
|
379
380
|
|
380
381
|
foo = newrelic.plugins.Workload("foo",
|
381
|
-
name="Example workload",
|
382
382
|
account_id=12345678,
|
383
383
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
384
384
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -386,14 +386,15 @@ class Workload(pulumi.CustomResource):
|
|
386
386
|
)],
|
387
387
|
scope_account_ids=[12345678])
|
388
388
|
```
|
389
|
+
<!--End PulumiCodeChooser -->
|
389
390
|
|
390
391
|
Include entities with a set of tags.
|
392
|
+
<!--Start PulumiCodeChooser -->
|
391
393
|
```python
|
392
394
|
import pulumi
|
393
395
|
import pulumi_newrelic as newrelic
|
394
396
|
|
395
397
|
foo = newrelic.plugins.Workload("foo",
|
396
|
-
name="Example workload with tags",
|
397
398
|
account_id=12345678,
|
398
399
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
399
400
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -401,14 +402,15 @@ class Workload(pulumi.CustomResource):
|
|
401
402
|
)],
|
402
403
|
scope_account_ids=[12345678])
|
403
404
|
```
|
405
|
+
<!--End PulumiCodeChooser -->
|
404
406
|
|
405
407
|
Include entities with a set of tags.
|
408
|
+
<!--Start PulumiCodeChooser -->
|
406
409
|
```python
|
407
410
|
import pulumi
|
408
411
|
import pulumi_newrelic as newrelic
|
409
412
|
|
410
413
|
foo = newrelic.plugins.Workload("foo",
|
411
|
-
name="Example workload with tags",
|
412
414
|
account_id=12345678,
|
413
415
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
414
416
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -416,73 +418,12 @@ class Workload(pulumi.CustomResource):
|
|
416
418
|
)],
|
417
419
|
scope_account_ids=[12345678])
|
418
420
|
```
|
421
|
+
<!--End PulumiCodeChooser -->
|
419
422
|
|
420
423
|
Include automatic status
|
421
424
|
|
422
425
|
> The global status of your workload is a quick indicator of the workload health. You can configure it to be calculated automatically, and you can also set an alert and get a notification whenever the workload stops being operational. Alternatively, you can communicate a certain status of the workload by setting up a static value and a description. [See our docs](https://docs.newrelic.com/docs/workloads/use-workloads/workloads/workload-status)
|
423
426
|
|
424
|
-
```python
|
425
|
-
import pulumi
|
426
|
-
import pulumi_newrelic as newrelic
|
427
|
-
|
428
|
-
foo = newrelic.plugins.Workload("foo",
|
429
|
-
name="Example workload",
|
430
|
-
account_id=12345678,
|
431
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
432
|
-
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
433
|
-
query="name like '%Example application%'",
|
434
|
-
)],
|
435
|
-
scope_account_ids=[12345678],
|
436
|
-
description="Description",
|
437
|
-
status_config_automatic=newrelic.plugins.WorkloadStatusConfigAutomaticArgs(
|
438
|
-
enabled=True,
|
439
|
-
remaining_entities_rule=newrelic.plugins.WorkloadStatusConfigAutomaticRemainingEntitiesRuleArgs(
|
440
|
-
remaining_entities_rule_rollup=newrelic.plugins.WorkloadStatusConfigAutomaticRemainingEntitiesRuleRemainingEntitiesRuleRollupArgs(
|
441
|
-
strategy="BEST_STATUS_WINS",
|
442
|
-
threshold_type="FIXED",
|
443
|
-
threshold_value=100,
|
444
|
-
group_by="ENTITY_TYPE",
|
445
|
-
),
|
446
|
-
),
|
447
|
-
rules=[newrelic.plugins.WorkloadStatusConfigAutomaticRuleArgs(
|
448
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
449
|
-
nrql_queries=[newrelic.plugins.WorkloadStatusConfigAutomaticRuleNrqlQueryArgs(
|
450
|
-
query="name like '%Example application2%'",
|
451
|
-
)],
|
452
|
-
rollup=newrelic.plugins.WorkloadStatusConfigAutomaticRuleRollupArgs(
|
453
|
-
strategy="BEST_STATUS_WINS",
|
454
|
-
threshold_type="FIXED",
|
455
|
-
threshold_value=100,
|
456
|
-
),
|
457
|
-
)],
|
458
|
-
))
|
459
|
-
```
|
460
|
-
|
461
|
-
Include static status
|
462
|
-
|
463
|
-
> You can use this during maintenance tasks or any other time you want to provide a fixed status for your workload. This overrides all automatic rules. [See our docs](https://docs.newrelic.com/docs/workloads/use-workloads/workloads/workload-status#configure-static)
|
464
|
-
|
465
|
-
```python
|
466
|
-
import pulumi
|
467
|
-
import pulumi_newrelic as newrelic
|
468
|
-
|
469
|
-
foo = newrelic.plugins.Workload("foo",
|
470
|
-
name="Example workload",
|
471
|
-
account_id=12345678,
|
472
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
473
|
-
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
474
|
-
query="name like '%Example application%'",
|
475
|
-
)],
|
476
|
-
scope_account_ids=[12345678],
|
477
|
-
description="Description",
|
478
|
-
status_config_static=newrelic.plugins.WorkloadStatusConfigStaticArgs(
|
479
|
-
description="test",
|
480
|
-
enabled=True,
|
481
|
-
status="OPERATIONAL",
|
482
|
-
summary="summary of the status",
|
483
|
-
))
|
484
|
-
```
|
485
|
-
|
486
427
|
## Import
|
487
428
|
|
488
429
|
New Relic workloads can be imported using a concatenated string of the format
|
@@ -499,12 +440,12 @@ class Workload(pulumi.CustomResource):
|
|
499
440
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
500
441
|
:param pulumi.Input[int] account_id: The New Relic account ID where you want to create the workload.
|
501
442
|
:param pulumi.Input[str] description: Relevant information about the workload.
|
502
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload.
|
503
|
-
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['WorkloadEntitySearchQueryArgs']]]] entity_search_queries: A list of search queries that define a dynamic workload.
|
443
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
444
|
+
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['WorkloadEntitySearchQueryArgs']]]] entity_search_queries: A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
504
445
|
:param pulumi.Input[str] name: The workload's name.
|
505
446
|
:param pulumi.Input[Sequence[pulumi.Input[int]]] scope_account_ids: A list of account IDs that will be used to get entities from.
|
506
|
-
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigAutomaticArgs']] status_config_automatic: An input object used to represent an automatic status configuration.
|
507
|
-
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigStaticArgs']] status_config_static: A list of static status configurations. You can only configure one static status for a workload.
|
447
|
+
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigAutomaticArgs']] status_config_automatic: An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
448
|
+
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigStaticArgs']] status_config_static: A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
508
449
|
"""
|
509
450
|
...
|
510
451
|
@overload
|
@@ -522,12 +463,12 @@ class Workload(pulumi.CustomResource):
|
|
522
463
|
## Example Usage
|
523
464
|
|
524
465
|
Include entities with a certain string on the name.
|
466
|
+
<!--Start PulumiCodeChooser -->
|
525
467
|
```python
|
526
468
|
import pulumi
|
527
469
|
import pulumi_newrelic as newrelic
|
528
470
|
|
529
471
|
foo = newrelic.plugins.Workload("foo",
|
530
|
-
name="Example workload",
|
531
472
|
account_id=12345678,
|
532
473
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
533
474
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -535,14 +476,15 @@ class Workload(pulumi.CustomResource):
|
|
535
476
|
)],
|
536
477
|
scope_account_ids=[12345678])
|
537
478
|
```
|
479
|
+
<!--End PulumiCodeChooser -->
|
538
480
|
|
539
481
|
Include entities with a set of tags.
|
482
|
+
<!--Start PulumiCodeChooser -->
|
540
483
|
```python
|
541
484
|
import pulumi
|
542
485
|
import pulumi_newrelic as newrelic
|
543
486
|
|
544
487
|
foo = newrelic.plugins.Workload("foo",
|
545
|
-
name="Example workload with tags",
|
546
488
|
account_id=12345678,
|
547
489
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
548
490
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -550,14 +492,15 @@ class Workload(pulumi.CustomResource):
|
|
550
492
|
)],
|
551
493
|
scope_account_ids=[12345678])
|
552
494
|
```
|
495
|
+
<!--End PulumiCodeChooser -->
|
553
496
|
|
554
497
|
Include entities with a set of tags.
|
498
|
+
<!--Start PulumiCodeChooser -->
|
555
499
|
```python
|
556
500
|
import pulumi
|
557
501
|
import pulumi_newrelic as newrelic
|
558
502
|
|
559
503
|
foo = newrelic.plugins.Workload("foo",
|
560
|
-
name="Example workload with tags",
|
561
504
|
account_id=12345678,
|
562
505
|
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
563
506
|
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
@@ -565,73 +508,12 @@ class Workload(pulumi.CustomResource):
|
|
565
508
|
)],
|
566
509
|
scope_account_ids=[12345678])
|
567
510
|
```
|
511
|
+
<!--End PulumiCodeChooser -->
|
568
512
|
|
569
513
|
Include automatic status
|
570
514
|
|
571
515
|
> The global status of your workload is a quick indicator of the workload health. You can configure it to be calculated automatically, and you can also set an alert and get a notification whenever the workload stops being operational. Alternatively, you can communicate a certain status of the workload by setting up a static value and a description. [See our docs](https://docs.newrelic.com/docs/workloads/use-workloads/workloads/workload-status)
|
572
516
|
|
573
|
-
```python
|
574
|
-
import pulumi
|
575
|
-
import pulumi_newrelic as newrelic
|
576
|
-
|
577
|
-
foo = newrelic.plugins.Workload("foo",
|
578
|
-
name="Example workload",
|
579
|
-
account_id=12345678,
|
580
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
581
|
-
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
582
|
-
query="name like '%Example application%'",
|
583
|
-
)],
|
584
|
-
scope_account_ids=[12345678],
|
585
|
-
description="Description",
|
586
|
-
status_config_automatic=newrelic.plugins.WorkloadStatusConfigAutomaticArgs(
|
587
|
-
enabled=True,
|
588
|
-
remaining_entities_rule=newrelic.plugins.WorkloadStatusConfigAutomaticRemainingEntitiesRuleArgs(
|
589
|
-
remaining_entities_rule_rollup=newrelic.plugins.WorkloadStatusConfigAutomaticRemainingEntitiesRuleRemainingEntitiesRuleRollupArgs(
|
590
|
-
strategy="BEST_STATUS_WINS",
|
591
|
-
threshold_type="FIXED",
|
592
|
-
threshold_value=100,
|
593
|
-
group_by="ENTITY_TYPE",
|
594
|
-
),
|
595
|
-
),
|
596
|
-
rules=[newrelic.plugins.WorkloadStatusConfigAutomaticRuleArgs(
|
597
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
598
|
-
nrql_queries=[newrelic.plugins.WorkloadStatusConfigAutomaticRuleNrqlQueryArgs(
|
599
|
-
query="name like '%Example application2%'",
|
600
|
-
)],
|
601
|
-
rollup=newrelic.plugins.WorkloadStatusConfigAutomaticRuleRollupArgs(
|
602
|
-
strategy="BEST_STATUS_WINS",
|
603
|
-
threshold_type="FIXED",
|
604
|
-
threshold_value=100,
|
605
|
-
),
|
606
|
-
)],
|
607
|
-
))
|
608
|
-
```
|
609
|
-
|
610
|
-
Include static status
|
611
|
-
|
612
|
-
> You can use this during maintenance tasks or any other time you want to provide a fixed status for your workload. This overrides all automatic rules. [See our docs](https://docs.newrelic.com/docs/workloads/use-workloads/workloads/workload-status#configure-static)
|
613
|
-
|
614
|
-
```python
|
615
|
-
import pulumi
|
616
|
-
import pulumi_newrelic as newrelic
|
617
|
-
|
618
|
-
foo = newrelic.plugins.Workload("foo",
|
619
|
-
name="Example workload",
|
620
|
-
account_id=12345678,
|
621
|
-
entity_guids=["MjUyMDUyOHxBUE18QVBQTElDQVRJT058MjE1MDM3Nzk1"],
|
622
|
-
entity_search_queries=[newrelic.plugins.WorkloadEntitySearchQueryArgs(
|
623
|
-
query="name like '%Example application%'",
|
624
|
-
)],
|
625
|
-
scope_account_ids=[12345678],
|
626
|
-
description="Description",
|
627
|
-
status_config_static=newrelic.plugins.WorkloadStatusConfigStaticArgs(
|
628
|
-
description="test",
|
629
|
-
enabled=True,
|
630
|
-
status="OPERATIONAL",
|
631
|
-
summary="summary of the status",
|
632
|
-
))
|
633
|
-
```
|
634
|
-
|
635
517
|
## Import
|
636
518
|
|
637
519
|
New Relic workloads can be imported using a concatenated string of the format
|
@@ -720,14 +602,14 @@ class Workload(pulumi.CustomResource):
|
|
720
602
|
:param pulumi.Input[int] account_id: The New Relic account ID where you want to create the workload.
|
721
603
|
:param pulumi.Input[str] composite_entity_search_query: The composite query used to compose a dynamic workload.
|
722
604
|
:param pulumi.Input[str] description: Relevant information about the workload.
|
723
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload.
|
724
|
-
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['WorkloadEntitySearchQueryArgs']]]] entity_search_queries: A list of search queries that define a dynamic workload.
|
605
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] entity_guids: A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
606
|
+
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['WorkloadEntitySearchQueryArgs']]]] entity_search_queries: A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
725
607
|
:param pulumi.Input[str] guid: The unique entity identifier of the workload in New Relic.
|
726
608
|
:param pulumi.Input[str] name: The workload's name.
|
727
609
|
:param pulumi.Input[str] permalink: The URL of the workload.
|
728
610
|
:param pulumi.Input[Sequence[pulumi.Input[int]]] scope_account_ids: A list of account IDs that will be used to get entities from.
|
729
|
-
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigAutomaticArgs']] status_config_automatic: An input object used to represent an automatic status configuration.
|
730
|
-
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigStaticArgs']] status_config_static: A list of static status configurations. You can only configure one static status for a workload.
|
611
|
+
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigAutomaticArgs']] status_config_automatic: An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
612
|
+
:param pulumi.Input[pulumi.InputType['WorkloadStatusConfigStaticArgs']] status_config_static: A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
731
613
|
:param pulumi.Input[int] workload_id: The unique entity identifier of the workload.
|
732
614
|
"""
|
733
615
|
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
@@ -776,7 +658,7 @@ class Workload(pulumi.CustomResource):
|
|
776
658
|
@pulumi.getter(name="entityGuids")
|
777
659
|
def entity_guids(self) -> pulumi.Output[Sequence[str]]:
|
778
660
|
"""
|
779
|
-
A list of entity GUIDs manually assigned to this workload.
|
661
|
+
A list of entity GUIDs manually assigned to this workload. At least one of either `entity_guids` or `entity_search_query` is required.
|
780
662
|
"""
|
781
663
|
return pulumi.get(self, "entity_guids")
|
782
664
|
|
@@ -784,7 +666,7 @@ class Workload(pulumi.CustomResource):
|
|
784
666
|
@pulumi.getter(name="entitySearchQueries")
|
785
667
|
def entity_search_queries(self) -> pulumi.Output[Optional[Sequence['outputs.WorkloadEntitySearchQuery']]]:
|
786
668
|
"""
|
787
|
-
A list of search queries that define a dynamic workload.
|
669
|
+
A list of search queries that define a dynamic workload. At least one of either `entity_guids` or `entity_search_query` is required. See Nested entity_search_query blocks below for details.
|
788
670
|
"""
|
789
671
|
return pulumi.get(self, "entity_search_queries")
|
790
672
|
|
@@ -824,7 +706,7 @@ class Workload(pulumi.CustomResource):
|
|
824
706
|
@pulumi.getter(name="statusConfigAutomatic")
|
825
707
|
def status_config_automatic(self) -> pulumi.Output[Optional['outputs.WorkloadStatusConfigAutomatic']]:
|
826
708
|
"""
|
827
|
-
An input object used to represent an automatic status configuration.
|
709
|
+
An input object used to represent an automatic status configuration.See Nested status_config_automatic blocks below for details.
|
828
710
|
"""
|
829
711
|
return pulumi.get(self, "status_config_automatic")
|
830
712
|
|
@@ -832,7 +714,7 @@ class Workload(pulumi.CustomResource):
|
|
832
714
|
@pulumi.getter(name="statusConfigStatic")
|
833
715
|
def status_config_static(self) -> pulumi.Output[Optional['outputs.WorkloadStatusConfigStatic']]:
|
834
716
|
"""
|
835
|
-
A list of static status configurations. You can only configure one static status for a workload.
|
717
|
+
A list of static status configurations. You can only configure one static status for a workload.See Nested status_config_static blocks below for details.
|
836
718
|
"""
|
837
719
|
return pulumi.get(self, "status_config_static")
|
838
720
|
|