Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR azure-mgmt-monitor] [Hub Generated] Review request for Microsoft.Insights to add version stable/2018-03-01 #3556

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -862,26 +862,24 @@ class MetricAlertResourcePatch(Model):
Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:param tags: Resource tags
:type tags: dict[str, str]
:param description: Required. the description of the metric alert that
will be included in the alert email.
:param description: the description of the metric alert that will be
included in the alert email.
:type description: str
:param severity: Required. Alert severity {0, 1, 2, 3, 4}
:param severity: Alert severity {0, 1, 2, 3, 4}
:type severity: int
:param enabled: Required. the flag that indicates whether the metric alert
is enabled.
:param enabled: the flag that indicates whether the metric alert is
enabled.
:type enabled: bool
:param scopes: the list of resource id's that this metric alert is scoped
to.
:type scopes: list[str]
:param evaluation_frequency: Required. how often the metric alert is
evaluated represented in ISO 8601 duration format.
:param evaluation_frequency: how often the metric alert is evaluated
represented in ISO 8601 duration format.
:type evaluation_frequency: timedelta
:param window_size: Required. the period of time (in ISO 8601 duration
format) that is used to monitor alert activity based on the threshold.
:param window_size: the period of time (in ISO 8601 duration format) that
is used to monitor alert activity based on the threshold.
:type window_size: timedelta
:param target_resource_type: the resource type of the target resource(s)
on which the alert is created/updated. Mandatory for
Expand All @@ -891,8 +889,7 @@ class MetricAlertResourcePatch(Model):
which the alert is created/updated. Mandatory for
MultipleResourceMultipleMetricCriteria.
:type target_resource_region: str
:param criteria: Required. defines the specific alert criteria
information.
:param criteria: defines the specific alert criteria information.
:type criteria: ~azure.mgmt.monitor.v2018_03_01.models.MetricAlertCriteria
:param auto_mitigate: the flag that indicates whether the alert should be
auto resolved or not. The default is true.
Expand All @@ -906,12 +903,6 @@ class MetricAlertResourcePatch(Model):
"""

_validation = {
'description': {'required': True},
'severity': {'required': True},
'enabled': {'required': True},
'evaluation_frequency': {'required': True},
'window_size': {'required': True},
'criteria': {'required': True},
'last_updated_time': {'readonly': True},
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -862,26 +862,24 @@ class MetricAlertResourcePatch(Model):
Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:param tags: Resource tags
:type tags: dict[str, str]
:param description: Required. the description of the metric alert that
will be included in the alert email.
:param description: the description of the metric alert that will be
included in the alert email.
:type description: str
:param severity: Required. Alert severity {0, 1, 2, 3, 4}
:param severity: Alert severity {0, 1, 2, 3, 4}
:type severity: int
:param enabled: Required. the flag that indicates whether the metric alert
is enabled.
:param enabled: the flag that indicates whether the metric alert is
enabled.
:type enabled: bool
:param scopes: the list of resource id's that this metric alert is scoped
to.
:type scopes: list[str]
:param evaluation_frequency: Required. how often the metric alert is
evaluated represented in ISO 8601 duration format.
:param evaluation_frequency: how often the metric alert is evaluated
represented in ISO 8601 duration format.
:type evaluation_frequency: timedelta
:param window_size: Required. the period of time (in ISO 8601 duration
format) that is used to monitor alert activity based on the threshold.
:param window_size: the period of time (in ISO 8601 duration format) that
is used to monitor alert activity based on the threshold.
:type window_size: timedelta
:param target_resource_type: the resource type of the target resource(s)
on which the alert is created/updated. Mandatory for
Expand All @@ -891,8 +889,7 @@ class MetricAlertResourcePatch(Model):
which the alert is created/updated. Mandatory for
MultipleResourceMultipleMetricCriteria.
:type target_resource_region: str
:param criteria: Required. defines the specific alert criteria
information.
:param criteria: defines the specific alert criteria information.
:type criteria: ~azure.mgmt.monitor.v2018_03_01.models.MetricAlertCriteria
:param auto_mitigate: the flag that indicates whether the alert should be
auto resolved or not. The default is true.
Expand All @@ -906,12 +903,6 @@ class MetricAlertResourcePatch(Model):
"""

_validation = {
'description': {'required': True},
'severity': {'required': True},
'enabled': {'required': True},
'evaluation_frequency': {'required': True},
'window_size': {'required': True},
'criteria': {'required': True},
'last_updated_time': {'readonly': True},
}

Expand All @@ -931,7 +922,7 @@ class MetricAlertResourcePatch(Model):
'last_updated_time': {'key': 'properties.lastUpdatedTime', 'type': 'iso-8601'},
}

def __init__(self, *, description: str, severity: int, enabled: bool, evaluation_frequency, window_size, criteria, tags=None, scopes=None, target_resource_type: str=None, target_resource_region: str=None, auto_mitigate: bool=None, actions=None, **kwargs) -> None:
def __init__(self, *, tags=None, description: str=None, severity: int=None, enabled: bool=None, scopes=None, evaluation_frequency=None, window_size=None, target_resource_type: str=None, target_resource_region: str=None, criteria=None, auto_mitigate: bool=None, actions=None, **kwargs) -> None:
super(MetricAlertResourcePatch, self).__init__(**kwargs)
self.tags = tags
self.description = description
Expand Down