pulumi-newrelic 5.21.0a1710157101__py3-none-any.whl → 5.39.0a1736834464__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- pulumi_newrelic/__init__.py +9 -0
- pulumi_newrelic/_inputs.py +7153 -461
- pulumi_newrelic/_utilities.py +41 -5
- pulumi_newrelic/account_management.py +11 -6
- pulumi_newrelic/alert_channel.py +116 -127
- pulumi_newrelic/alert_condition.py +116 -129
- pulumi_newrelic/alert_muting_rule.py +128 -76
- pulumi_newrelic/alert_policy.py +78 -75
- pulumi_newrelic/alert_policy_channel.py +77 -68
- pulumi_newrelic/api_access_key.py +45 -28
- pulumi_newrelic/browser_application.py +77 -78
- pulumi_newrelic/cloud/_inputs.py +2527 -1082
- pulumi_newrelic/cloud/aws_govcloud_integrations.py +133 -128
- pulumi_newrelic/cloud/aws_govcloud_link_account.py +23 -20
- pulumi_newrelic/cloud/aws_integrations.py +298 -1326
- pulumi_newrelic/cloud/aws_link_account.py +23 -20
- pulumi_newrelic/cloud/azure_integrations.py +521 -483
- pulumi_newrelic/cloud/azure_link_account.py +34 -31
- pulumi_newrelic/cloud/gcp_integrations.py +341 -322
- pulumi_newrelic/cloud/gcp_link_account.py +23 -20
- pulumi_newrelic/cloud/outputs.py +327 -1072
- pulumi_newrelic/config/__init__.pyi +6 -1
- pulumi_newrelic/config/vars.py +7 -2
- pulumi_newrelic/data_partition_rule.py +19 -18
- pulumi_newrelic/entity_tags.py +32 -31
- pulumi_newrelic/events_to_metrics_rule.py +23 -20
- pulumi_newrelic/get_account.py +24 -16
- pulumi_newrelic/get_alert_channel.py +26 -13
- pulumi_newrelic/get_alert_policy.py +35 -12
- pulumi_newrelic/get_application.py +39 -31
- pulumi_newrelic/get_authentication_domain.py +17 -13
- pulumi_newrelic/get_cloud_account.py +26 -18
- pulumi_newrelic/get_entity.py +90 -147
- pulumi_newrelic/get_group.py +58 -13
- pulumi_newrelic/get_key_transaction.py +109 -34
- pulumi_newrelic/get_notification_destination.py +64 -14
- pulumi_newrelic/get_obfuscation_expression.py +36 -28
- pulumi_newrelic/get_service_level_alert_helper.py +135 -117
- pulumi_newrelic/get_test_grok_pattern.py +29 -18
- pulumi_newrelic/get_user.py +17 -9
- pulumi_newrelic/group.py +5 -146
- pulumi_newrelic/infra_alert_condition.py +160 -167
- pulumi_newrelic/insights/_inputs.py +43 -0
- pulumi_newrelic/insights/event.py +48 -47
- pulumi_newrelic/insights/outputs.py +5 -0
- pulumi_newrelic/key_transaction.py +464 -0
- pulumi_newrelic/log_parsing_rule.py +25 -24
- pulumi_newrelic/monitor_downtime.py +211 -225
- pulumi_newrelic/notification_channel.py +381 -366
- pulumi_newrelic/notification_destination.py +192 -54
- pulumi_newrelic/nrql_alert_condition.py +345 -262
- pulumi_newrelic/nrql_drop_rule.py +31 -30
- pulumi_newrelic/obfuscation_expression.py +23 -20
- pulumi_newrelic/obfuscation_rule.py +38 -33
- pulumi_newrelic/one_dashboard.py +29 -24
- pulumi_newrelic/one_dashboard_json.py +19 -14
- pulumi_newrelic/one_dashboard_raw.py +110 -105
- pulumi_newrelic/outputs.py +2446 -245
- pulumi_newrelic/plugins/_inputs.py +145 -10
- pulumi_newrelic/plugins/application_settings.py +25 -36
- pulumi_newrelic/plugins/outputs.py +15 -10
- pulumi_newrelic/plugins/workload.py +215 -92
- pulumi_newrelic/provider.py +27 -33
- pulumi_newrelic/pulumi-plugin.json +2 -1
- pulumi_newrelic/service_level.py +185 -186
- pulumi_newrelic/synthetics/_inputs.py +159 -2
- pulumi_newrelic/synthetics/alert_condition.py +87 -98
- pulumi_newrelic/synthetics/broken_links_monitor.py +216 -99
- pulumi_newrelic/synthetics/cert_check_monitor.py +219 -100
- pulumi_newrelic/synthetics/get_private_location.py +34 -30
- pulumi_newrelic/synthetics/get_secure_credential.py +24 -16
- pulumi_newrelic/synthetics/monitor.py +348 -193
- pulumi_newrelic/synthetics/multi_location_alert_condition.py +105 -100
- pulumi_newrelic/synthetics/outputs.py +7 -2
- pulumi_newrelic/synthetics/private_location.py +25 -20
- pulumi_newrelic/synthetics/script_monitor.py +317 -182
- pulumi_newrelic/synthetics/secure_credential.py +23 -22
- pulumi_newrelic/synthetics/step_monitor.py +405 -100
- pulumi_newrelic/user.py +13 -10
- pulumi_newrelic/workflow.py +209 -196
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736834464.dist-info}/METADATA +7 -6
- pulumi_newrelic-5.39.0a1736834464.dist-info/RECORD +90 -0
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736834464.dist-info}/WHEEL +1 -1
- pulumi_newrelic-5.21.0a1710157101.dist-info/RECORD +0 -89
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736834464.dist-info}/top_level.txt +0 -0
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
from . import outputs
|
12
17
|
|
@@ -23,8 +28,8 @@ class GetAlertChannelResult:
|
|
23
28
|
A collection of values returned by getAlertChannel.
|
24
29
|
"""
|
25
30
|
def __init__(__self__, account_id=None, config=None, id=None, name=None, policy_ids=None, type=None):
|
26
|
-
if account_id and not isinstance(account_id,
|
27
|
-
raise TypeError("Expected argument 'account_id' to be a
|
31
|
+
if account_id and not isinstance(account_id, str):
|
32
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
28
33
|
pulumi.set(__self__, "account_id", account_id)
|
29
34
|
if config and not isinstance(config, dict):
|
30
35
|
raise TypeError("Expected argument 'config' to be a dict")
|
@@ -44,7 +49,7 @@ class GetAlertChannelResult:
|
|
44
49
|
|
45
50
|
@property
|
46
51
|
@pulumi.getter(name="accountId")
|
47
|
-
def account_id(self) ->
|
52
|
+
def account_id(self) -> str:
|
48
53
|
return pulumi.get(self, "account_id")
|
49
54
|
|
50
55
|
@property
|
@@ -70,7 +75,7 @@ class GetAlertChannelResult:
|
|
70
75
|
|
71
76
|
@property
|
72
77
|
@pulumi.getter(name="policyIds")
|
73
|
-
def policy_ids(self) -> Sequence[
|
78
|
+
def policy_ids(self) -> Sequence[str]:
|
74
79
|
"""
|
75
80
|
A list of policy IDs associated with the alert channel.
|
76
81
|
"""
|
@@ -99,7 +104,7 @@ class AwaitableGetAlertChannelResult(GetAlertChannelResult):
|
|
99
104
|
type=self.type)
|
100
105
|
|
101
106
|
|
102
|
-
def get_alert_channel(account_id: Optional[
|
107
|
+
def get_alert_channel(account_id: Optional[str] = None,
|
103
108
|
name: Optional[str] = None,
|
104
109
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetAlertChannelResult:
|
105
110
|
"""
|
@@ -108,7 +113,7 @@ def get_alert_channel(account_id: Optional[int] = None,
|
|
108
113
|
> **WARNING:** The `AlertChannel` data source is deprecated and will be removed in the next major release.
|
109
114
|
|
110
115
|
|
111
|
-
:param
|
116
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
112
117
|
:param str name: The name of the alert channel in New Relic.
|
113
118
|
"""
|
114
119
|
__args__ = dict()
|
@@ -124,19 +129,27 @@ def get_alert_channel(account_id: Optional[int] = None,
|
|
124
129
|
name=pulumi.get(__ret__, 'name'),
|
125
130
|
policy_ids=pulumi.get(__ret__, 'policy_ids'),
|
126
131
|
type=pulumi.get(__ret__, 'type'))
|
127
|
-
|
128
|
-
|
129
|
-
@_utilities.lift_output_func(get_alert_channel)
|
130
|
-
def get_alert_channel_output(account_id: Optional[pulumi.Input[Optional[int]]] = None,
|
132
|
+
def get_alert_channel_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
131
133
|
name: Optional[pulumi.Input[str]] = None,
|
132
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetAlertChannelResult]:
|
134
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetAlertChannelResult]:
|
133
135
|
"""
|
134
136
|
Use this data source to get information about a specific alert channel in New Relic that already exists.
|
135
137
|
|
136
138
|
> **WARNING:** The `AlertChannel` data source is deprecated and will be removed in the next major release.
|
137
139
|
|
138
140
|
|
139
|
-
:param
|
141
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
140
142
|
:param str name: The name of the alert channel in New Relic.
|
141
143
|
"""
|
142
|
-
|
144
|
+
__args__ = dict()
|
145
|
+
__args__['accountId'] = account_id
|
146
|
+
__args__['name'] = name
|
147
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
148
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getAlertChannel:getAlertChannel', __args__, opts=opts, typ=GetAlertChannelResult)
|
149
|
+
return __ret__.apply(lambda __response__: GetAlertChannelResult(
|
150
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
151
|
+
config=pulumi.get(__response__, 'config'),
|
152
|
+
id=pulumi.get(__response__, 'id'),
|
153
|
+
name=pulumi.get(__response__, 'name'),
|
154
|
+
policy_ids=pulumi.get(__response__, 'policy_ids'),
|
155
|
+
type=pulumi.get(__response__, 'type')))
|
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -22,8 +27,8 @@ class GetAlertPolicyResult:
|
|
22
27
|
A collection of values returned by getAlertPolicy.
|
23
28
|
"""
|
24
29
|
def __init__(__self__, account_id=None, created_at=None, id=None, incident_preference=None, name=None, updated_at=None):
|
25
|
-
if account_id and not isinstance(account_id,
|
26
|
-
raise TypeError("Expected argument 'account_id' to be a
|
30
|
+
if account_id and not isinstance(account_id, str):
|
31
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
27
32
|
pulumi.set(__self__, "account_id", account_id)
|
28
33
|
if created_at and not isinstance(created_at, str):
|
29
34
|
raise TypeError("Expected argument 'created_at' to be a str")
|
@@ -43,7 +48,7 @@ class GetAlertPolicyResult:
|
|
43
48
|
|
44
49
|
@property
|
45
50
|
@pulumi.getter(name="accountId")
|
46
|
-
def account_id(self) ->
|
51
|
+
def account_id(self) -> str:
|
47
52
|
return pulumi.get(self, "account_id")
|
48
53
|
|
49
54
|
@property
|
@@ -67,6 +72,9 @@ class GetAlertPolicyResult:
|
|
67
72
|
def incident_preference(self) -> Optional[str]:
|
68
73
|
"""
|
69
74
|
The rollup strategy for the policy, which can have one of the following values:
|
75
|
+
* `PER_POLICY` - Represents the incident grouping preference **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.
|
76
|
+
* `PER_CONDITION` - Represents the incident grouping preference **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.
|
77
|
+
* `PER_CONDITION_AND_TARGET` - Represents the incident grouping preference **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.
|
70
78
|
"""
|
71
79
|
return pulumi.get(self, "incident_preference")
|
72
80
|
|
@@ -98,7 +106,7 @@ class AwaitableGetAlertPolicyResult(GetAlertPolicyResult):
|
|
98
106
|
updated_at=self.updated_at)
|
99
107
|
|
100
108
|
|
101
|
-
def get_alert_policy(account_id: Optional[
|
109
|
+
def get_alert_policy(account_id: Optional[str] = None,
|
102
110
|
incident_preference: Optional[str] = None,
|
103
111
|
name: Optional[str] = None,
|
104
112
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetAlertPolicyResult:
|
@@ -106,8 +114,11 @@ def get_alert_policy(account_id: Optional[int] = None,
|
|
106
114
|
Use this data source to get information about a specific alert policy in New Relic that already exists.
|
107
115
|
|
108
116
|
|
109
|
-
:param
|
117
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
110
118
|
:param str incident_preference: The rollup strategy for the policy, which can have one of the following values:
|
119
|
+
* `PER_POLICY` - Represents the incident grouping preference **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.
|
120
|
+
* `PER_CONDITION` - Represents the incident grouping preference **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.
|
121
|
+
* `PER_CONDITION_AND_TARGET` - Represents the incident grouping preference **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.
|
111
122
|
:param str name: The name of the alert policy in New Relic.
|
112
123
|
"""
|
113
124
|
__args__ = dict()
|
@@ -124,19 +135,31 @@ def get_alert_policy(account_id: Optional[int] = None,
|
|
124
135
|
incident_preference=pulumi.get(__ret__, 'incident_preference'),
|
125
136
|
name=pulumi.get(__ret__, 'name'),
|
126
137
|
updated_at=pulumi.get(__ret__, 'updated_at'))
|
127
|
-
|
128
|
-
|
129
|
-
@_utilities.lift_output_func(get_alert_policy)
|
130
|
-
def get_alert_policy_output(account_id: Optional[pulumi.Input[Optional[int]]] = None,
|
138
|
+
def get_alert_policy_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
131
139
|
incident_preference: Optional[pulumi.Input[Optional[str]]] = None,
|
132
140
|
name: Optional[pulumi.Input[str]] = None,
|
133
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetAlertPolicyResult]:
|
141
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetAlertPolicyResult]:
|
134
142
|
"""
|
135
143
|
Use this data source to get information about a specific alert policy in New Relic that already exists.
|
136
144
|
|
137
145
|
|
138
|
-
:param
|
146
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
139
147
|
:param str incident_preference: The rollup strategy for the policy, which can have one of the following values:
|
148
|
+
* `PER_POLICY` - Represents the incident grouping preference **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.
|
149
|
+
* `PER_CONDITION` - Represents the incident grouping preference **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.
|
150
|
+
* `PER_CONDITION_AND_TARGET` - Represents the incident grouping preference **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.
|
140
151
|
:param str name: The name of the alert policy in New Relic.
|
141
152
|
"""
|
142
|
-
|
153
|
+
__args__ = dict()
|
154
|
+
__args__['accountId'] = account_id
|
155
|
+
__args__['incidentPreference'] = incident_preference
|
156
|
+
__args__['name'] = name
|
157
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
158
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getAlertPolicy:getAlertPolicy', __args__, opts=opts, typ=GetAlertPolicyResult)
|
159
|
+
return __ret__.apply(lambda __response__: GetAlertPolicyResult(
|
160
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
161
|
+
created_at=pulumi.get(__response__, 'created_at'),
|
162
|
+
id=pulumi.get(__response__, 'id'),
|
163
|
+
incident_preference=pulumi.get(__response__, 'incident_preference'),
|
164
|
+
name=pulumi.get(__response__, 'name'),
|
165
|
+
updated_at=pulumi.get(__response__, 'updated_at')))
|
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -37,7 +42,7 @@ class GetApplicationResult:
|
|
37
42
|
|
38
43
|
@property
|
39
44
|
@pulumi.getter(name="hostIds")
|
40
|
-
def host_ids(self) -> Sequence[
|
45
|
+
def host_ids(self) -> Sequence[str]:
|
41
46
|
"""
|
42
47
|
A list of host IDs associated with the application.
|
43
48
|
"""
|
@@ -53,7 +58,7 @@ class GetApplicationResult:
|
|
53
58
|
|
54
59
|
@property
|
55
60
|
@pulumi.getter(name="instanceIds")
|
56
|
-
def instance_ids(self) -> Sequence[
|
61
|
+
def instance_ids(self) -> Sequence[str]:
|
57
62
|
"""
|
58
63
|
A list of instance IDs associated with the application.
|
59
64
|
"""
|
@@ -86,28 +91,27 @@ def get_application(name: Optional[str] = None,
|
|
86
91
|
|
87
92
|
## Example Usage
|
88
93
|
|
89
|
-
<!--Start PulumiCodeChooser -->
|
90
94
|
```python
|
91
95
|
import pulumi
|
92
96
|
import pulumi_newrelic as newrelic
|
93
97
|
|
94
98
|
app = newrelic.get_application(name="my-app")
|
95
|
-
|
96
|
-
foo_alert_condition = newrelic.AlertCondition("
|
97
|
-
policy_id=
|
99
|
+
foo = newrelic.AlertPolicy("foo", name="foo")
|
100
|
+
foo_alert_condition = newrelic.AlertCondition("foo",
|
101
|
+
policy_id=foo.id,
|
102
|
+
name="foo",
|
98
103
|
type="apm_app_metric",
|
99
104
|
entities=[app.id],
|
100
105
|
metric="apdex",
|
101
106
|
runbook_url="https://www.example.com",
|
102
|
-
terms=[
|
103
|
-
duration
|
104
|
-
operator
|
105
|
-
priority
|
106
|
-
threshold
|
107
|
-
time_function
|
108
|
-
|
107
|
+
terms=[{
|
108
|
+
"duration": 5,
|
109
|
+
"operator": "below",
|
110
|
+
"priority": "critical",
|
111
|
+
"threshold": 0.75,
|
112
|
+
"time_function": "all",
|
113
|
+
}])
|
109
114
|
```
|
110
|
-
<!--End PulumiCodeChooser -->
|
111
115
|
|
112
116
|
|
113
117
|
:param str name: The name of the application in New Relic.
|
@@ -122,11 +126,8 @@ def get_application(name: Optional[str] = None,
|
|
122
126
|
id=pulumi.get(__ret__, 'id'),
|
123
127
|
instance_ids=pulumi.get(__ret__, 'instance_ids'),
|
124
128
|
name=pulumi.get(__ret__, 'name'))
|
125
|
-
|
126
|
-
|
127
|
-
@_utilities.lift_output_func(get_application)
|
128
129
|
def get_application_output(name: Optional[pulumi.Input[str]] = None,
|
129
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetApplicationResult]:
|
130
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetApplicationResult]:
|
130
131
|
"""
|
131
132
|
#### DEPRECATED! Use at your own risk. Use the `get_entity` data source instead. This feature may be removed in the next major release
|
132
133
|
|
@@ -134,30 +135,37 @@ def get_application_output(name: Optional[pulumi.Input[str]] = None,
|
|
134
135
|
|
135
136
|
## Example Usage
|
136
137
|
|
137
|
-
<!--Start PulumiCodeChooser -->
|
138
138
|
```python
|
139
139
|
import pulumi
|
140
140
|
import pulumi_newrelic as newrelic
|
141
141
|
|
142
142
|
app = newrelic.get_application(name="my-app")
|
143
|
-
|
144
|
-
foo_alert_condition = newrelic.AlertCondition("
|
145
|
-
policy_id=
|
143
|
+
foo = newrelic.AlertPolicy("foo", name="foo")
|
144
|
+
foo_alert_condition = newrelic.AlertCondition("foo",
|
145
|
+
policy_id=foo.id,
|
146
|
+
name="foo",
|
146
147
|
type="apm_app_metric",
|
147
148
|
entities=[app.id],
|
148
149
|
metric="apdex",
|
149
150
|
runbook_url="https://www.example.com",
|
150
|
-
terms=[
|
151
|
-
duration
|
152
|
-
operator
|
153
|
-
priority
|
154
|
-
threshold
|
155
|
-
time_function
|
156
|
-
|
151
|
+
terms=[{
|
152
|
+
"duration": 5,
|
153
|
+
"operator": "below",
|
154
|
+
"priority": "critical",
|
155
|
+
"threshold": 0.75,
|
156
|
+
"time_function": "all",
|
157
|
+
}])
|
157
158
|
```
|
158
|
-
<!--End PulumiCodeChooser -->
|
159
159
|
|
160
160
|
|
161
161
|
:param str name: The name of the application in New Relic.
|
162
162
|
"""
|
163
|
-
|
163
|
+
__args__ = dict()
|
164
|
+
__args__['name'] = name
|
165
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
166
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getApplication:getApplication', __args__, opts=opts, typ=GetApplicationResult)
|
167
|
+
return __ret__.apply(lambda __response__: GetApplicationResult(
|
168
|
+
host_ids=pulumi.get(__response__, 'host_ids'),
|
169
|
+
id=pulumi.get(__response__, 'id'),
|
170
|
+
instance_ids=pulumi.get(__response__, 'instance_ids'),
|
171
|
+
name=pulumi.get(__response__, 'name')))
|
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -60,15 +65,13 @@ def get_authentication_domain(name: Optional[str] = None,
|
|
60
65
|
|
61
66
|
## Example Usage
|
62
67
|
|
63
|
-
<!--Start PulumiCodeChooser -->
|
64
68
|
```python
|
65
69
|
import pulumi
|
66
70
|
import pulumi_newrelic as newrelic
|
67
71
|
|
68
|
-
|
69
|
-
pulumi.export("foo",
|
72
|
+
foo = newrelic.get_authentication_domain(name="Test Authentication Domain")
|
73
|
+
pulumi.export("foo", foo.id)
|
70
74
|
```
|
71
|
-
<!--End PulumiCodeChooser -->
|
72
75
|
|
73
76
|
|
74
77
|
:param str name: The name of the authentication domain to be searched for. An error is thrown, if no authentication domain is found with the specified name.
|
@@ -81,27 +84,28 @@ def get_authentication_domain(name: Optional[str] = None,
|
|
81
84
|
return AwaitableGetAuthenticationDomainResult(
|
82
85
|
id=pulumi.get(__ret__, 'id'),
|
83
86
|
name=pulumi.get(__ret__, 'name'))
|
84
|
-
|
85
|
-
|
86
|
-
@_utilities.lift_output_func(get_authentication_domain)
|
87
87
|
def get_authentication_domain_output(name: Optional[pulumi.Input[str]] = None,
|
88
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetAuthenticationDomainResult]:
|
88
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetAuthenticationDomainResult]:
|
89
89
|
"""
|
90
90
|
Use this data source to fetch the ID of an authentication domain belonging to your account, matching the specified name.
|
91
91
|
|
92
92
|
## Example Usage
|
93
93
|
|
94
|
-
<!--Start PulumiCodeChooser -->
|
95
94
|
```python
|
96
95
|
import pulumi
|
97
96
|
import pulumi_newrelic as newrelic
|
98
97
|
|
99
|
-
|
100
|
-
pulumi.export("foo",
|
98
|
+
foo = newrelic.get_authentication_domain(name="Test Authentication Domain")
|
99
|
+
pulumi.export("foo", foo.id)
|
101
100
|
```
|
102
|
-
<!--End PulumiCodeChooser -->
|
103
101
|
|
104
102
|
|
105
103
|
:param str name: The name of the authentication domain to be searched for. An error is thrown, if no authentication domain is found with the specified name.
|
106
104
|
"""
|
107
|
-
|
105
|
+
__args__ = dict()
|
106
|
+
__args__['name'] = name
|
107
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
108
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getAuthenticationDomain:getAuthenticationDomain', __args__, opts=opts, typ=GetAuthenticationDomainResult)
|
109
|
+
return __ret__.apply(lambda __response__: GetAuthenticationDomainResult(
|
110
|
+
id=pulumi.get(__response__, 'id'),
|
111
|
+
name=pulumi.get(__response__, 'name')))
|
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -22,8 +27,8 @@ class GetCloudAccountResult:
|
|
22
27
|
A collection of values returned by getCloudAccount.
|
23
28
|
"""
|
24
29
|
def __init__(__self__, account_id=None, cloud_provider=None, id=None, name=None):
|
25
|
-
if account_id and not isinstance(account_id,
|
26
|
-
raise TypeError("Expected argument 'account_id' to be a
|
30
|
+
if account_id and not isinstance(account_id, str):
|
31
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
27
32
|
pulumi.set(__self__, "account_id", account_id)
|
28
33
|
if cloud_provider and not isinstance(cloud_provider, str):
|
29
34
|
raise TypeError("Expected argument 'cloud_provider' to be a str")
|
@@ -37,7 +42,7 @@ class GetCloudAccountResult:
|
|
37
42
|
|
38
43
|
@property
|
39
44
|
@pulumi.getter(name="accountId")
|
40
|
-
def account_id(self) -> Optional[
|
45
|
+
def account_id(self) -> Optional[str]:
|
41
46
|
return pulumi.get(self, "account_id")
|
42
47
|
|
43
48
|
@property
|
@@ -71,7 +76,7 @@ class AwaitableGetCloudAccountResult(GetCloudAccountResult):
|
|
71
76
|
name=self.name)
|
72
77
|
|
73
78
|
|
74
|
-
def get_cloud_account(account_id: Optional[
|
79
|
+
def get_cloud_account(account_id: Optional[str] = None,
|
75
80
|
cloud_provider: Optional[str] = None,
|
76
81
|
name: Optional[str] = None,
|
77
82
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetCloudAccountResult:
|
@@ -81,19 +86,17 @@ def get_cloud_account(account_id: Optional[int] = None,
|
|
81
86
|
|
82
87
|
## Example Usage
|
83
88
|
|
84
|
-
<!--Start PulumiCodeChooser -->
|
85
89
|
```python
|
86
90
|
import pulumi
|
87
91
|
import pulumi_newrelic as newrelic
|
88
92
|
|
89
|
-
account = newrelic.get_cloud_account(account_id=12345,
|
93
|
+
account = newrelic.get_cloud_account(account_id="12345",
|
90
94
|
cloud_provider="aws",
|
91
95
|
name="my aws account")
|
92
96
|
```
|
93
|
-
<!--End PulumiCodeChooser -->
|
94
97
|
|
95
98
|
|
96
|
-
:param
|
99
|
+
:param str account_id: The account ID in New Relic.
|
97
100
|
:param str cloud_provider: The cloud provider of the account (aws, gcp, azure, etc)
|
98
101
|
:param str name: The cloud account name in New Relic.
|
99
102
|
"""
|
@@ -109,33 +112,38 @@ def get_cloud_account(account_id: Optional[int] = None,
|
|
109
112
|
cloud_provider=pulumi.get(__ret__, 'cloud_provider'),
|
110
113
|
id=pulumi.get(__ret__, 'id'),
|
111
114
|
name=pulumi.get(__ret__, 'name'))
|
112
|
-
|
113
|
-
|
114
|
-
@_utilities.lift_output_func(get_cloud_account)
|
115
|
-
def get_cloud_account_output(account_id: Optional[pulumi.Input[Optional[int]]] = None,
|
115
|
+
def get_cloud_account_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
116
116
|
cloud_provider: Optional[pulumi.Input[str]] = None,
|
117
117
|
name: Optional[pulumi.Input[str]] = None,
|
118
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCloudAccountResult]:
|
118
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCloudAccountResult]:
|
119
119
|
"""
|
120
120
|
Use this data source to get information about a specific cloud account linked to New Relic.
|
121
121
|
Accounts can be located by a combination of New Relic Account ID, name and cloud provider (aws, gcp, azure, etc). Name and cloud provider are required attributes. If no account_id is specified on the resource the provider level account_id will be used.
|
122
122
|
|
123
123
|
## Example Usage
|
124
124
|
|
125
|
-
<!--Start PulumiCodeChooser -->
|
126
125
|
```python
|
127
126
|
import pulumi
|
128
127
|
import pulumi_newrelic as newrelic
|
129
128
|
|
130
|
-
account = newrelic.get_cloud_account(account_id=12345,
|
129
|
+
account = newrelic.get_cloud_account(account_id="12345",
|
131
130
|
cloud_provider="aws",
|
132
131
|
name="my aws account")
|
133
132
|
```
|
134
|
-
<!--End PulumiCodeChooser -->
|
135
133
|
|
136
134
|
|
137
|
-
:param
|
135
|
+
:param str account_id: The account ID in New Relic.
|
138
136
|
:param str cloud_provider: The cloud provider of the account (aws, gcp, azure, etc)
|
139
137
|
:param str name: The cloud account name in New Relic.
|
140
138
|
"""
|
141
|
-
|
139
|
+
__args__ = dict()
|
140
|
+
__args__['accountId'] = account_id
|
141
|
+
__args__['cloudProvider'] = cloud_provider
|
142
|
+
__args__['name'] = name
|
143
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
144
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getCloudAccount:getCloudAccount', __args__, opts=opts, typ=GetCloudAccountResult)
|
145
|
+
return __ret__.apply(lambda __response__: GetCloudAccountResult(
|
146
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
147
|
+
cloud_provider=pulumi.get(__response__, 'cloud_provider'),
|
148
|
+
id=pulumi.get(__response__, 'id'),
|
149
|
+
name=pulumi.get(__response__, 'name')))
|