Skip to content

Commit

Permalink
azure-mgmt-monitor 0.5.2 (#2460)
Browse files Browse the repository at this point in the history
* [AutoPR monitor/resource-manager] Added GA API version for Scheduled Query Rule (#2416)

* Generated from d183bad923d3a0a4092d21203f850db6cde9f4e9

Resolving Comments

Resolving Comments

* Generated from df40ac3bbf17ea0180dd4adff2af3094065feca0

Made SKU as top level proprty and including generic error response format

Couple of changes -
1. Made SKU as top level proprty as mentioned here - https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/resource-api-reference.md#put-resource
 2. including generic error response format

* Generated from 7578160670750a68d05f77ec8163b25bb72f391e

Minor Changes to align implementation

1. Removed SKU - Billing Model is still under discussion, hence need not to be exposed to customers.
2.  Enabled field ichanged to align with camel case.
3.  'throttleTillDate' in properties.action changed to 'throttlingInMin' to denote correct meaning  and it’s data type changed to number instead of date.
4. 'status' to be removed in properties.action from examples.
5.  'severity' made a required field in properties.action.
6. Removed Examples from original spec json

* Generated from fb180fb311d73934d0f5150f72638cc3de155ea0

Added Default Response payload in all APIs

Changes -
1. Added Default Response payload in all APIs
2. Made azNs description more clear

* Generated from fb180fb311d73934d0f5150f72638cc3de155ea0

Added Default Response payload in all APIs

Changes -
1. Added Default Response payload in all APIs
2. Made azNs description more clear

* [AutoPR monitor/resource-manager] Minor Updates - description text (#2513)

* Generated from 0c826790271a1be2d4af5905ee0eb089b4260feb

Merge pull request #1 from abversqr/MinorUpdates

Minor updates

* Generated from 1610a74a5c49c73a546972daca1e7a43798a8cea

Merge branch 'master' into master

* [AutoPR monitor/resource-manager] Add "autoMitigate" to Metric Alert API spec for 2018-03-01 (#2592)

* Generated from d5b9b4545a8d15c70d3c8318d39e2f7b43229387

AutoMitigate changes

* Generated from d5b9b4545a8d15c70d3c8318d39e2f7b43229387

AutoMitigate changes

* [AutoPR monitor/resource-manager] [Monitor] Deconflict "Action" name in MetricAlert (#2617)

* Generated from 35adc5e493c20a57e6e2cb35d87c578133d2b7a6

[Monitor] Deconflict "Action" name in MetricAlert

Generates bad SDK.

* Generated from ebfaf0bdd7f2bcf736598d8ec501f490a83d1268

Update reference to MetricAlertAction

* [AutoPR monitor/resource-manager] Adding patch support for SQR API (#2596)

* Generated from f53526896e5c001f79bd46ca892f825172b53abf

Merge branch 'master' into patchsupport

* Generated from f53526896e5c001f79bd46ca892f825172b53abf

Merge branch 'master' into patchsupport

* Generated from b37d3ace14508e3bc3f87ee29b7f2ad0b7025f67

Resolving multiple model issue

Changes - 
1. Renamed "MetricTrigger" to "LogMetricTrigger"
2. Aligned "Resources" to other specs

* Rebuild by #2460

* Auto packaging
  • Loading branch information
AutorestCI authored and lmazuel committed Jun 6, 2018
1 parent 7b0b19d commit fb6d5da
Show file tree
Hide file tree
Showing 71 changed files with 3,504 additions and 24 deletions.
82 changes: 82 additions & 0 deletions azure-mgmt-monitor/azure/mgmt/monitor/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@
from .itsm_receiver_py3 import ItsmReceiver
from .azure_app_push_receiver_py3 import AzureAppPushReceiver
from .automation_runbook_receiver_py3 import AutomationRunbookReceiver
from .voice_receiver_py3 import VoiceReceiver
from .logic_app_receiver_py3 import LogicAppReceiver
from .azure_function_receiver_py3 import AzureFunctionReceiver
from .action_group_resource_py3 import ActionGroupResource
from .enable_request_py3 import EnableRequest
from .action_group_patch_body_py3 import ActionGroupPatchBody
Expand All @@ -84,6 +87,25 @@
from .baseline_response_py3 import BaselineResponse
from .time_series_information_py3 import TimeSeriesInformation
from .calculate_baseline_response_py3 import CalculateBaselineResponse
from .metric_alert_action_py3 import MetricAlertAction
from .metric_alert_criteria_py3 import MetricAlertCriteria
from .metric_alert_resource_py3 import MetricAlertResource
from .metric_alert_resource_patch_py3 import MetricAlertResourcePatch
from .metric_alert_status_properties_py3 import MetricAlertStatusProperties
from .metric_alert_status_py3 import MetricAlertStatus
from .metric_alert_status_collection_py3 import MetricAlertStatusCollection
from .metric_dimension_py3 import MetricDimension
from .metric_criteria_py3 import MetricCriteria
from .metric_alert_single_resource_multiple_metric_criteria_py3 import MetricAlertSingleResourceMultipleMetricCriteria
from .source_py3 import Source
from .schedule_py3 import Schedule
from .action_py3 import Action
from .log_search_rule_resource_py3 import LogSearchRuleResource
from .log_search_rule_resource_patch_py3 import LogSearchRuleResourcePatch
from .log_metric_trigger_py3 import LogMetricTrigger
from .trigger_condition_py3 import TriggerCondition
from .az_ns_action_group_py3 import AzNsActionGroup
from .alerting_action_py3 import AlertingAction
except (SyntaxError, ImportError):
from .resource import Resource
from .scale_capacity import ScaleCapacity
Expand Down Expand Up @@ -134,6 +156,9 @@
from .itsm_receiver import ItsmReceiver
from .azure_app_push_receiver import AzureAppPushReceiver
from .automation_runbook_receiver import AutomationRunbookReceiver
from .voice_receiver import VoiceReceiver
from .logic_app_receiver import LogicAppReceiver
from .azure_function_receiver import AzureFunctionReceiver
from .action_group_resource import ActionGroupResource
from .enable_request import EnableRequest
from .action_group_patch_body import ActionGroupPatchBody
Expand All @@ -159,6 +184,25 @@
from .baseline_response import BaselineResponse
from .time_series_information import TimeSeriesInformation
from .calculate_baseline_response import CalculateBaselineResponse
from .metric_alert_action import MetricAlertAction
from .metric_alert_criteria import MetricAlertCriteria
from .metric_alert_resource import MetricAlertResource
from .metric_alert_resource_patch import MetricAlertResourcePatch
from .metric_alert_status_properties import MetricAlertStatusProperties
from .metric_alert_status import MetricAlertStatus
from .metric_alert_status_collection import MetricAlertStatusCollection
from .metric_dimension import MetricDimension
from .metric_criteria import MetricCriteria
from .metric_alert_single_resource_multiple_metric_criteria import MetricAlertSingleResourceMultipleMetricCriteria
from .source import Source
from .schedule import Schedule
from .action import Action
from .log_search_rule_resource import LogSearchRuleResource
from .log_search_rule_resource_patch import LogSearchRuleResourcePatch
from .log_metric_trigger import LogMetricTrigger
from .trigger_condition import TriggerCondition
from .az_ns_action_group import AzNsActionGroup
from .alerting_action import AlertingAction
from .autoscale_setting_resource_paged import AutoscaleSettingResourcePaged
from .incident_paged import IncidentPaged
from .alert_rule_resource_paged import AlertRuleResourcePaged
Expand All @@ -168,6 +212,8 @@
from .event_data_paged import EventDataPaged
from .localizable_string_paged import LocalizableStringPaged
from .metric_definition_paged import MetricDefinitionPaged
from .metric_alert_resource_paged import MetricAlertResourcePaged
from .log_search_rule_resource_paged import LogSearchRuleResourcePaged
from .monitor_management_client_enums import (
MetricStatisticType,
TimeAggregationType,
Expand All @@ -183,6 +229,12 @@
Unit,
AggregationType,
Sensitivity,
Enabled,
ProvisioningState,
QueryType,
ConditionalOperator,
MetricTriggerType,
AlertSeverity,
ResultType,
)

Expand Down Expand Up @@ -236,6 +288,9 @@
'ItsmReceiver',
'AzureAppPushReceiver',
'AutomationRunbookReceiver',
'VoiceReceiver',
'LogicAppReceiver',
'AzureFunctionReceiver',
'ActionGroupResource',
'EnableRequest',
'ActionGroupPatchBody',
Expand All @@ -261,6 +316,25 @@
'BaselineResponse',
'TimeSeriesInformation',
'CalculateBaselineResponse',
'MetricAlertAction',
'MetricAlertCriteria',
'MetricAlertResource',
'MetricAlertResourcePatch',
'MetricAlertStatusProperties',
'MetricAlertStatus',
'MetricAlertStatusCollection',
'MetricDimension',
'MetricCriteria',
'MetricAlertSingleResourceMultipleMetricCriteria',
'Source',
'Schedule',
'Action',
'LogSearchRuleResource',
'LogSearchRuleResourcePatch',
'LogMetricTrigger',
'TriggerCondition',
'AzNsActionGroup',
'AlertingAction',
'AutoscaleSettingResourcePaged',
'IncidentPaged',
'AlertRuleResourcePaged',
Expand All @@ -270,6 +344,8 @@
'EventDataPaged',
'LocalizableStringPaged',
'MetricDefinitionPaged',
'MetricAlertResourcePaged',
'LogSearchRuleResourcePaged',
'MetricStatisticType',
'TimeAggregationType',
'ComparisonOperationType',
Expand All @@ -284,5 +360,11 @@
'Unit',
'AggregationType',
'Sensitivity',
'Enabled',
'ProvisioningState',
'QueryType',
'ConditionalOperator',
'MetricTriggerType',
'AlertSeverity',
'ResultType',
]
41 changes: 41 additions & 0 deletions azure-mgmt-monitor/azure/mgmt/monitor/models/action.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class Action(Model):
"""Action.
You probably want to use the sub-classes and not this class directly. Known
sub-classes are: AlertingAction
All required parameters must be populated in order to send to Azure.
:param odatatype: Required. Constant filled by server.
:type odatatype: str
"""

_validation = {
'odatatype': {'required': True},
}

_attribute_map = {
'odatatype': {'key': 'odata\\.type', 'type': 'str'},
}

_subtype_map = {
'odatatype': {'Microsoft.WindowsAzure.Management.Monitoring.Alerts.Models.Microsoft.AppInsights.Nexus.DataContracts.Resources.ScheduledQueryRules.AlertingAction': 'AlertingAction'}
}

def __init__(self, **kwargs):
super(Action, self).__init__(**kwargs)
self.odatatype = None
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,25 @@ class ActionGroupResource(Resource):
receivers that are part of this action group.
:type automation_runbook_receivers:
list[~azure.mgmt.monitor.models.AutomationRunbookReceiver]
:param voice_receivers: The list of voice receivers that are part of this
action group.
:type voice_receivers: list[~azure.mgmt.monitor.models.VoiceReceiver]
:param logic_app_receivers: The list of logic app receivers that are part
of this action group.
:type logic_app_receivers:
list[~azure.mgmt.monitor.models.LogicAppReceiver]
:param azure_function_receivers: The list of azure function receivers that
are part of this action group.
:type azure_function_receivers:
list[~azure.mgmt.monitor.models.AzureFunctionReceiver]
"""

_validation = {
'id': {'readonly': True},
'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 All @@ -82,6 +93,9 @@ class ActionGroupResource(Resource):
'itsm_receivers': {'key': 'properties.itsmReceivers', 'type': '[ItsmReceiver]'},
'azure_app_push_receivers': {'key': 'properties.azureAppPushReceivers', 'type': '[AzureAppPushReceiver]'},
'automation_runbook_receivers': {'key': 'properties.automationRunbookReceivers', 'type': '[AutomationRunbookReceiver]'},
'voice_receivers': {'key': 'properties.voiceReceivers', 'type': '[VoiceReceiver]'},
'logic_app_receivers': {'key': 'properties.logicAppReceivers', 'type': '[LogicAppReceiver]'},
'azure_function_receivers': {'key': 'properties.azureFunctionReceivers', 'type': '[AzureFunctionReceiver]'},
}

def __init__(self, **kwargs):
Expand All @@ -94,3 +108,6 @@ def __init__(self, **kwargs):
self.itsm_receivers = kwargs.get('itsm_receivers', None)
self.azure_app_push_receivers = kwargs.get('azure_app_push_receivers', None)
self.automation_runbook_receivers = kwargs.get('automation_runbook_receivers', None)
self.voice_receivers = kwargs.get('voice_receivers', None)
self.logic_app_receivers = kwargs.get('logic_app_receivers', None)
self.azure_function_receivers = kwargs.get('azure_function_receivers', None)
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class ActionGroupResource(Resource):
Expand Down Expand Up @@ -57,14 +57,25 @@ class ActionGroupResource(Resource):
receivers that are part of this action group.
:type automation_runbook_receivers:
list[~azure.mgmt.monitor.models.AutomationRunbookReceiver]
:param voice_receivers: The list of voice receivers that are part of this
action group.
:type voice_receivers: list[~azure.mgmt.monitor.models.VoiceReceiver]
:param logic_app_receivers: The list of logic app receivers that are part
of this action group.
:type logic_app_receivers:
list[~azure.mgmt.monitor.models.LogicAppReceiver]
:param azure_function_receivers: The list of azure function receivers that
are part of this action group.
:type azure_function_receivers:
list[~azure.mgmt.monitor.models.AzureFunctionReceiver]
"""

_validation = {
'id': {'readonly': True},
'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 All @@ -82,9 +93,12 @@ class ActionGroupResource(Resource):
'itsm_receivers': {'key': 'properties.itsmReceivers', 'type': '[ItsmReceiver]'},
'azure_app_push_receivers': {'key': 'properties.azureAppPushReceivers', 'type': '[AzureAppPushReceiver]'},
'automation_runbook_receivers': {'key': 'properties.automationRunbookReceivers', 'type': '[AutomationRunbookReceiver]'},
'voice_receivers': {'key': 'properties.voiceReceivers', 'type': '[VoiceReceiver]'},
'logic_app_receivers': {'key': 'properties.logicAppReceivers', 'type': '[LogicAppReceiver]'},
'azure_function_receivers': {'key': 'properties.azureFunctionReceivers', 'type': '[AzureFunctionReceiver]'},
}

def __init__(self, *, location: str, group_short_name: str, tags=None, enabled: bool=True, email_receivers=None, sms_receivers=None, webhook_receivers=None, itsm_receivers=None, azure_app_push_receivers=None, automation_runbook_receivers=None, **kwargs) -> None:
def __init__(self, *, location: str, group_short_name: str, tags=None, enabled: bool=True, email_receivers=None, sms_receivers=None, webhook_receivers=None, itsm_receivers=None, azure_app_push_receivers=None, automation_runbook_receivers=None, voice_receivers=None, logic_app_receivers=None, azure_function_receivers=None, **kwargs) -> None:
super(ActionGroupResource, self).__init__(location=location, tags=tags, **kwargs)
self.group_short_name = group_short_name
self.enabled = enabled
Expand All @@ -94,3 +108,6 @@ def __init__(self, *, location: str, group_short_name: str, tags=None, enabled:
self.itsm_receivers = itsm_receivers
self.azure_app_push_receivers = azure_app_push_receivers
self.automation_runbook_receivers = automation_runbook_receivers
self.voice_receivers = voice_receivers
self.logic_app_receivers = logic_app_receivers
self.azure_function_receivers = azure_function_receivers
41 changes: 41 additions & 0 deletions azure-mgmt-monitor/azure/mgmt/monitor/models/action_py3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class Action(Model):
"""Action.
You probably want to use the sub-classes and not this class directly. Known
sub-classes are: AlertingAction
All required parameters must be populated in order to send to Azure.
:param odatatype: Required. Constant filled by server.
:type odatatype: str
"""

_validation = {
'odatatype': {'required': True},
}

_attribute_map = {
'odatatype': {'key': 'odata\\.type', 'type': 'str'},
}

_subtype_map = {
'odatatype': {'Microsoft.WindowsAzure.Management.Monitoring.Alerts.Models.Microsoft.AppInsights.Nexus.DataContracts.Resources.ScheduledQueryRules.AlertingAction': 'AlertingAction'}
}

def __init__(self, **kwargs) -> None:
super(Action, self).__init__(**kwargs)
self.odatatype = None
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class ActivityLogAlertResource(Resource):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class AlertRuleResource(Resource):
Expand Down
Loading

0 comments on commit fb6d5da

Please sign in to comment.