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 network/resource-manager] Remove duplicate enums from Network specs #4849

Merged
merged 3 commits into from
Apr 19, 2019
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 @@ -10,6 +10,8 @@
# --------------------------------------------------------------------------

try:
from .application_gateway_probe_health_response_match_py3 import ApplicationGatewayProbeHealthResponseMatch
from .application_gateway_on_demand_probe_py3 import ApplicationGatewayOnDemandProbe
from .network_interface_tap_configuration_py3 import NetworkInterfaceTapConfiguration
from .sub_resource_py3 import SubResource
from .application_security_group_py3 import ApplicationSecurityGroup
Expand Down Expand Up @@ -46,6 +48,7 @@
from .application_gateway_backend_http_settings_py3 import ApplicationGatewayBackendHttpSettings
from .application_gateway_backend_health_server_py3 import ApplicationGatewayBackendHealthServer
from .application_gateway_backend_health_http_settings_py3 import ApplicationGatewayBackendHealthHttpSettings
from .application_gateway_backend_health_on_demand_py3 import ApplicationGatewayBackendHealthOnDemand
from .application_gateway_backend_health_pool_py3 import ApplicationGatewayBackendHealthPool
from .application_gateway_backend_health_py3 import ApplicationGatewayBackendHealth
from .application_gateway_sku_py3 import ApplicationGatewaySku
Expand All @@ -59,7 +62,6 @@
from .application_gateway_custom_error_py3 import ApplicationGatewayCustomError
from .application_gateway_http_listener_py3 import ApplicationGatewayHttpListener
from .application_gateway_path_rule_py3 import ApplicationGatewayPathRule
from .application_gateway_probe_health_response_match_py3 import ApplicationGatewayProbeHealthResponseMatch
from .application_gateway_probe_py3 import ApplicationGatewayProbe
from .application_gateway_request_routing_rule_py3 import ApplicationGatewayRequestRoutingRule
from .application_gateway_rewrite_rule_condition_py3 import ApplicationGatewayRewriteRuleCondition
Expand Down Expand Up @@ -305,6 +307,8 @@
from .web_application_firewall_custom_rule_py3 import WebApplicationFirewallCustomRule
from .web_application_firewall_policy_py3 import WebApplicationFirewallPolicy
except (SyntaxError, ImportError):
from .application_gateway_probe_health_response_match import ApplicationGatewayProbeHealthResponseMatch
from .application_gateway_on_demand_probe import ApplicationGatewayOnDemandProbe
from .network_interface_tap_configuration import NetworkInterfaceTapConfiguration
from .sub_resource import SubResource
from .application_security_group import ApplicationSecurityGroup
Expand Down Expand Up @@ -341,6 +345,7 @@
from .application_gateway_backend_http_settings import ApplicationGatewayBackendHttpSettings
from .application_gateway_backend_health_server import ApplicationGatewayBackendHealthServer
from .application_gateway_backend_health_http_settings import ApplicationGatewayBackendHealthHttpSettings
from .application_gateway_backend_health_on_demand import ApplicationGatewayBackendHealthOnDemand
from .application_gateway_backend_health_pool import ApplicationGatewayBackendHealthPool
from .application_gateway_backend_health import ApplicationGatewayBackendHealth
from .application_gateway_sku import ApplicationGatewaySku
Expand All @@ -354,7 +359,6 @@
from .application_gateway_custom_error import ApplicationGatewayCustomError
from .application_gateway_http_listener import ApplicationGatewayHttpListener
from .application_gateway_path_rule import ApplicationGatewayPathRule
from .application_gateway_probe_health_response_match import ApplicationGatewayProbeHealthResponseMatch
from .application_gateway_probe import ApplicationGatewayProbe
from .application_gateway_request_routing_rule import ApplicationGatewayRequestRoutingRule
from .application_gateway_rewrite_rule_condition import ApplicationGatewayRewriteRuleCondition
Expand Down Expand Up @@ -666,6 +670,7 @@
from .p2_svpn_gateway_paged import P2SVpnGatewayPaged
from .web_application_firewall_policy_paged import WebApplicationFirewallPolicyPaged
from .network_management_client_enums import (
ApplicationGatewayProtocol,
IPAllocationMethod,
SecurityRuleProtocol,
SecurityRuleAccess,
Expand All @@ -675,7 +680,6 @@
IPVersion,
DdosSettingsProtectionCoverage,
TransportProtocol,
ApplicationGatewayProtocol,
ApplicationGatewayCookieBasedAffinity,
ApplicationGatewayBackendHealthServerHealth,
ApplicationGatewaySkuName,
Expand Down Expand Up @@ -717,6 +721,7 @@
LoadBalancerOutboundRuleProtocol,
NatGatewaySkuName,
NetworkOperationStatus,
AuthenticationMethod,
EffectiveSecurityRuleProtocol,
EffectiveRouteSource,
EffectiveRouteState,
Expand Down Expand Up @@ -753,7 +758,6 @@
PfsGroup,
BgpPeerState,
ProcessorArchitecture,
AuthenticationMethod,
VirtualNetworkGatewayConnectionStatus,
VirtualNetworkGatewayConnectionType,
VirtualNetworkGatewayConnectionProtocol,
Expand All @@ -774,6 +778,8 @@
)

__all__ = [
'ApplicationGatewayProbeHealthResponseMatch',
'ApplicationGatewayOnDemandProbe',
'NetworkInterfaceTapConfiguration',
'SubResource',
'ApplicationSecurityGroup',
Expand Down Expand Up @@ -810,6 +816,7 @@
'ApplicationGatewayBackendHttpSettings',
'ApplicationGatewayBackendHealthServer',
'ApplicationGatewayBackendHealthHttpSettings',
'ApplicationGatewayBackendHealthOnDemand',
'ApplicationGatewayBackendHealthPool',
'ApplicationGatewayBackendHealth',
'ApplicationGatewaySku',
Expand All @@ -823,7 +830,6 @@
'ApplicationGatewayCustomError',
'ApplicationGatewayHttpListener',
'ApplicationGatewayPathRule',
'ApplicationGatewayProbeHealthResponseMatch',
'ApplicationGatewayProbe',
'ApplicationGatewayRequestRoutingRule',
'ApplicationGatewayRewriteRuleCondition',
Expand Down Expand Up @@ -1134,6 +1140,7 @@
'P2SVpnServerConfigurationPaged',
'P2SVpnGatewayPaged',
'WebApplicationFirewallPolicyPaged',
'ApplicationGatewayProtocol',
'IPAllocationMethod',
'SecurityRuleProtocol',
'SecurityRuleAccess',
Expand All @@ -1143,7 +1150,6 @@
'IPVersion',
'DdosSettingsProtectionCoverage',
'TransportProtocol',
'ApplicationGatewayProtocol',
'ApplicationGatewayCookieBasedAffinity',
'ApplicationGatewayBackendHealthServerHealth',
'ApplicationGatewaySkuName',
Expand Down Expand Up @@ -1185,6 +1191,7 @@
'LoadBalancerOutboundRuleProtocol',
'NatGatewaySkuName',
'NetworkOperationStatus',
'AuthenticationMethod',
'EffectiveSecurityRuleProtocol',
'EffectiveRouteSource',
'EffectiveRouteState',
Expand Down Expand Up @@ -1221,7 +1228,6 @@
'PfsGroup',
'BgpPeerState',
'ProcessorArchitecture',
'AuthenticationMethod',
'VirtualNetworkGatewayConnectionStatus',
'VirtualNetworkGatewayConnectionType',
'VirtualNetworkGatewayConnectionProtocol',
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# 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 ApplicationGatewayBackendHealthOnDemand(Model):
"""Result of on demand test probe.

:param backend_address_pool: Reference of an
ApplicationGatewayBackendAddressPool resource.
:type backend_address_pool:
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayBackendAddressPool
:param backend_health_http_settings: Application gateway BackendHealthHttp
settings.
:type backend_health_http_settings:
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayBackendHealthHttpSettings
"""

_attribute_map = {
'backend_address_pool': {'key': 'backendAddressPool', 'type': 'ApplicationGatewayBackendAddressPool'},
'backend_health_http_settings': {'key': 'backendHealthHttpSettings', 'type': 'ApplicationGatewayBackendHealthHttpSettings'},
}

def __init__(self, **kwargs):
super(ApplicationGatewayBackendHealthOnDemand, self).__init__(**kwargs)
self.backend_address_pool = kwargs.get('backend_address_pool', None)
self.backend_health_http_settings = kwargs.get('backend_health_http_settings', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# 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 ApplicationGatewayBackendHealthOnDemand(Model):
"""Result of on demand test probe.

:param backend_address_pool: Reference of an
ApplicationGatewayBackendAddressPool resource.
:type backend_address_pool:
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayBackendAddressPool
:param backend_health_http_settings: Application gateway BackendHealthHttp
settings.
:type backend_health_http_settings:
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayBackendHealthHttpSettings
"""

_attribute_map = {
'backend_address_pool': {'key': 'backendAddressPool', 'type': 'ApplicationGatewayBackendAddressPool'},
'backend_health_http_settings': {'key': 'backendHealthHttpSettings', 'type': 'ApplicationGatewayBackendHealthHttpSettings'},
}

def __init__(self, *, backend_address_pool=None, backend_health_http_settings=None, **kwargs) -> None:
super(ApplicationGatewayBackendHealthOnDemand, self).__init__(**kwargs)
self.backend_address_pool = backend_address_pool
self.backend_health_http_settings = backend_health_http_settings
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ class ApplicationGatewayBackendHttpSettings(SubResource):
:param port: The destination port on the backend.
:type port: int
:param protocol: The protocol used to communicate with the backend.
Possible values are 'Http' and 'Https'. Possible values include: 'Http',
'Https'
Possible values include: 'Http', 'Https'
:type protocol: str or
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProtocol
:param cookie_based_affinity: Cookie based affinity. Possible values
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ class ApplicationGatewayBackendHttpSettings(SubResource):
:param port: The destination port on the backend.
:type port: int
:param protocol: The protocol used to communicate with the backend.
Possible values are 'Http' and 'Https'. Possible values include: 'Http',
'Https'
Possible values include: 'Http', 'Https'
:type protocol: str or
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProtocol
:param cookie_based_affinity: Cookie based affinity. Possible values
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ class ApplicationGatewayFrontendIPConfiguration(SubResource):
:param private_ip_address: PrivateIPAddress of the network interface IP
Configuration.
:type private_ip_address: str
:param private_ip_allocation_method: PrivateIP allocation method. Possible
values include: 'Static', 'Dynamic'
:param private_ip_allocation_method: The private IP address allocation
method. Possible values include: 'Static', 'Dynamic'
:type private_ip_allocation_method: str or
~azure.mgmt.network.v2019_02_01.models.IPAllocationMethod
:param subnet: Reference of the subnet resource.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ class ApplicationGatewayFrontendIPConfiguration(SubResource):
:param private_ip_address: PrivateIPAddress of the network interface IP
Configuration.
:type private_ip_address: str
:param private_ip_allocation_method: PrivateIP allocation method. Possible
values include: 'Static', 'Dynamic'
:param private_ip_allocation_method: The private IP address allocation
method. Possible values include: 'Static', 'Dynamic'
:type private_ip_allocation_method: str or
~azure.mgmt.network.v2019_02_01.models.IPAllocationMethod
:param subnet: Reference of the subnet resource.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ class ApplicationGatewayHttpListener(SubResource):
~azure.mgmt.network.v2019_02_01.models.SubResource
:param frontend_port: Frontend port resource of an application gateway.
:type frontend_port: ~azure.mgmt.network.v2019_02_01.models.SubResource
:param protocol: Protocol of the HTTP listener. Possible values are 'Http'
and 'Https'. Possible values include: 'Http', 'Https'
:param protocol: Protocol of the HTTP listener. Possible values include:
'Http', 'Https'
:type protocol: str or
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProtocol
:param host_name: Host name of HTTP listener.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ class ApplicationGatewayHttpListener(SubResource):
~azure.mgmt.network.v2019_02_01.models.SubResource
:param frontend_port: Frontend port resource of an application gateway.
:type frontend_port: ~azure.mgmt.network.v2019_02_01.models.SubResource
:param protocol: Protocol of the HTTP listener. Possible values are 'Http'
and 'Https'. Possible values include: 'Http', 'Https'
:param protocol: Protocol of the HTTP listener. Possible values include:
'Http', 'Https'
:type protocol: str or
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProtocol
:param host_name: Host name of HTTP listener.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# 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 ApplicationGatewayOnDemandProbe(Model):
"""Details of on demand test probe request.

:param protocol: The protocol used for the probe. Possible values are
'Http' and 'Https'. Possible values include: 'Http', 'Https'
:type protocol: str or
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProtocol
:param host: Host name to send the probe to.
:type host: str
:param path: Relative path of probe. Valid path starts from '/'. Probe is
sent to <Protocol>://<host>:<port><path>
:type path: str
:param timeout: The probe timeout in seconds. Probe marked as failed if
valid response is not received with this timeout period. Acceptable values
are from 1 second to 86400 seconds.
:type timeout: int
:param pick_host_name_from_backend_http_settings: Whether the host header
should be picked from the backend http settings. Default value is false.
:type pick_host_name_from_backend_http_settings: bool
:param match: Criterion for classifying a healthy probe response.
:type match:
~azure.mgmt.network.v2019_02_01.models.ApplicationGatewayProbeHealthResponseMatch
:param backend_pool_name: Name of backend pool of application gateway to
which probe request will be sent.
:type backend_pool_name: str
:param backend_http_setting_name: Name of backend http setting of
application gateway to be used for test probe
:type backend_http_setting_name: str
"""

_attribute_map = {
'protocol': {'key': 'protocol', 'type': 'str'},
'host': {'key': 'host', 'type': 'str'},
'path': {'key': 'path', 'type': 'str'},
'timeout': {'key': 'timeout', 'type': 'int'},
'pick_host_name_from_backend_http_settings': {'key': 'pickHostNameFromBackendHttpSettings', 'type': 'bool'},
'match': {'key': 'match', 'type': 'ApplicationGatewayProbeHealthResponseMatch'},
'backend_pool_name': {'key': 'backendPoolName', 'type': 'str'},
'backend_http_setting_name': {'key': 'backendHttpSettingName', 'type': 'str'},
}

def __init__(self, **kwargs):
super(ApplicationGatewayOnDemandProbe, self).__init__(**kwargs)
self.protocol = kwargs.get('protocol', None)
self.host = kwargs.get('host', None)
self.path = kwargs.get('path', None)
self.timeout = kwargs.get('timeout', None)
self.pick_host_name_from_backend_http_settings = kwargs.get('pick_host_name_from_backend_http_settings', None)
self.match = kwargs.get('match', None)
self.backend_pool_name = kwargs.get('backend_pool_name', None)
self.backend_http_setting_name = kwargs.get('backend_http_setting_name', None)
Loading