Skip to content
Merged
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 @@ -75,7 +75,7 @@ class ActionGroupResource(Resource):
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
'group_short_name': {'required': True, 'max_length': 15},
'group_short_name': {'required': True, 'max_length': 12},
'enabled': {'required': True},
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class ActionGroupResource(Resource):
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
'group_short_name': {'required': True, 'max_length': 15},
'group_short_name': {'required': True, 'max_length': 12},
'enabled': {'required': True},
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ class AlertingAction(Action):
:param severity: Required. Severity of the alert. Possible values include:
'0', '1', '2', '3', '4'
:type severity: str or ~azure.mgmt.monitor.models.AlertSeverity
:param azns_action: Required. azns notification group reference.
:param azns_action: Required. Azure action group reference.
:type azns_action: ~azure.mgmt.monitor.models.AzNsActionGroup
:param throttling_in_min: time (in minutes) for which Alerts should be
throttled
throttled or suppressed.
:type throttling_in_min: int
:param trigger: Required. The trigger condition that results in the alert
rule being.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ class AlertingAction(Action):
:param severity: Required. Severity of the alert. Possible values include:
'0', '1', '2', '3', '4'
:type severity: str or ~azure.mgmt.monitor.models.AlertSeverity
:param azns_action: Required. azns notification group reference.
:param azns_action: Required. Azure action group reference.
:type azns_action: ~azure.mgmt.monitor.models.AzNsActionGroup
:param throttling_in_min: time (in minutes) for which Alerts should be
throttled
throttled or suppressed.
:type throttling_in_min: int
:param trigger: Required. The trigger condition that results in the alert
rule being.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,15 @@


class AzNsActionGroup(Model):
"""azns notification group.
"""Azure action group.

:param action_group: Azure Group reference.
:param action_group: Azure Action Group reference.
:type action_group: list[str]
:param email_subject: Custom subject for Azns email
:type email_subject: str
:param custom_webhook_payload: Custom webhook payload to be send to azns
:param email_subject: Custom subject override for all email ids in Azure
action group
:type email_subject: str
:param custom_webhook_payload: Custom payload to be sent for all webook
URI in Azure action group
:type custom_webhook_payload: str
"""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,15 @@


class AzNsActionGroup(Model):
"""azns notification group.
"""Azure action group.

:param action_group: Azure Group reference.
:param action_group: Azure Action Group reference.
:type action_group: list[str]
:param email_subject: Custom subject for Azns email
:type email_subject: str
:param custom_webhook_payload: Custom webhook payload to be send to azns
:param email_subject: Custom subject override for all email ids in Azure
action group
:type email_subject: str
:param custom_webhook_payload: Custom payload to be sent for all webook
URI in Azure action group
:type custom_webhook_payload: str
"""

Expand Down
10 changes: 5 additions & 5 deletions azure-mgmt-monitor/azure/mgmt/monitor/models/source.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ class Source(Model):
:type query: str
:param authorized_resources: List of Resource referred into query
:type authorized_resources: list[str]
:param datasource_id: Required. The resource uri over which log search
:param data_source_id: Required. The resource uri over which log search
query is to be run.
:type datasource_id: str
:type data_source_id: str
:param query_type: Set value to ResultCount if query should be returning
search result count. Set it to Number if its a metric query. Possible
values include: 'ResultCount'
Expand All @@ -32,19 +32,19 @@ class Source(Model):

_validation = {
'query': {'required': True},
'datasource_id': {'required': True},
'data_source_id': {'required': True},
}

_attribute_map = {
'query': {'key': 'query', 'type': 'str'},
'authorized_resources': {'key': 'authorizedResources', 'type': '[str]'},
'datasource_id': {'key': 'datasourceId', 'type': 'str'},
'data_source_id': {'key': 'dataSourceId', 'type': 'str'},
'query_type': {'key': 'queryType', 'type': 'str'},
}

def __init__(self, **kwargs):
super(Source, self).__init__(**kwargs)
self.query = kwargs.get('query', None)
self.authorized_resources = kwargs.get('authorized_resources', None)
self.datasource_id = kwargs.get('datasource_id', None)
self.data_source_id = kwargs.get('data_source_id', None)
self.query_type = kwargs.get('query_type', None)
12 changes: 6 additions & 6 deletions azure-mgmt-monitor/azure/mgmt/monitor/models/source_py3.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ class Source(Model):
:type query: str
:param authorized_resources: List of Resource referred into query
:type authorized_resources: list[str]
:param datasource_id: Required. The resource uri over which log search
:param data_source_id: Required. The resource uri over which log search
query is to be run.
:type datasource_id: str
:type data_source_id: str
:param query_type: Set value to ResultCount if query should be returning
search result count. Set it to Number if its a metric query. Possible
values include: 'ResultCount'
Expand All @@ -32,19 +32,19 @@ class Source(Model):

_validation = {
'query': {'required': True},
'datasource_id': {'required': True},
'data_source_id': {'required': True},
}

_attribute_map = {
'query': {'key': 'query', 'type': 'str'},
'authorized_resources': {'key': 'authorizedResources', 'type': '[str]'},
'datasource_id': {'key': 'datasourceId', 'type': 'str'},
'data_source_id': {'key': 'dataSourceId', 'type': 'str'},
'query_type': {'key': 'queryType', 'type': 'str'},
}

def __init__(self, *, query: str, datasource_id: str, authorized_resources=None, query_type=None, **kwargs) -> None:
def __init__(self, *, query: str, data_source_id: str, authorized_resources=None, query_type=None, **kwargs) -> None:
super(Source, self).__init__(**kwargs)
self.query = query
self.authorized_resources = authorized_resources
self.datasource_id = datasource_id
self.data_source_id = data_source_id
self.query_type = query_type