Skip to content

Commit

Permalink
release-customproviders-for-mgmt-0.1.0 (#10160)
Browse files Browse the repository at this point in the history
* release-customproviders-for-mgmt-0.1.0

* change mgmt client name

* version preview

* no need to add rc for 0.1.0

Co-authored-by: qiaozha <qiaozha@mirosoft.com>
  • Loading branch information
qiaozha and qiaozha authored Mar 10, 2020
1 parent fc48c96 commit 1a3a438
Show file tree
Hide file tree
Showing 23 changed files with 2,306 additions and 0 deletions.
5 changes: 5 additions & 0 deletions sdk/customproviders/azure-mgmt-customproviders/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Release History

## 0.1.0 (2020-03-08)

* Initial Release
5 changes: 5 additions & 0 deletions sdk/customproviders/azure-mgmt-customproviders/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
recursive-include tests *.py *.yaml
include *.md
include azure/__init__.py
include azure/mgmt/__init__.py

21 changes: 21 additions & 0 deletions sdk/customproviders/azure-mgmt-customproviders/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Microsoft Azure SDK for Python

This is the Microsoft Azure CustomProviders Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/sdk)


# Usage

For code examples, see [CustomProviders Management](https://docs.microsoft.com/python/api/overview/azure/customproviders)
on docs.microsoft.com.


# Provide Feedback

If you encounter any bugs or have suggestions, please file an issue in the
[Issues](https://github.com/Azure/azure-sdk-for-python/issues)
section of the project.


![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-customproviders%2FREADME.png)
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# 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 ._configuration import CustomProvidersClientConfiguration
from ._custom_providers_client import CustomProvidersClient
__all__ = ['CustomProvidersClient', 'CustomProvidersClientConfiguration']

from .version import VERSION

__version__ = VERSION

Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# 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 msrestazure import AzureConfiguration

from .version import VERSION


class CustomProvidersClientConfiguration(AzureConfiguration):
"""Configuration for CustomProvidersClient
Note that all parameters used to create this instance are saved as instance
attributes.
:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: The Azure subscription ID. This is a
GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000)
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

if credentials is None:
raise ValueError("Parameter 'credentials' must not be None.")
if subscription_id is None:
raise ValueError("Parameter 'subscription_id' must not be None.")
if not base_url:
base_url = 'https://management.azure.com'

super(CustomProvidersClientConfiguration, self).__init__(base_url)

# Starting Autorest.Python 4.0.64, make connection pool activated by default
self.keep_alive = True

self.add_user_agent('azure-mgmt-customproviders/{}'.format(VERSION))
self.add_user_agent('Azure-SDK-For-Python')

self.credentials = credentials
self.subscription_id = subscription_id
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# 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.service_client import SDKClient
from msrest import Serializer, Deserializer

from ._configuration import CustomProvidersClientConfiguration
from .operations import Operations
from .operations import CustomResourceProviderOperations
from .operations import AssociationsOperations
from . import models


class CustomProvidersClient(SDKClient):
"""Allows extension of ARM control plane with custom resource providers.
:ivar config: Configuration for client.
:vartype config: CustomProvidersClientConfiguration
:ivar operations: Operations operations
:vartype operations: azure.mgmt.customproviders.operations.Operations
:ivar custom_resource_provider: CustomResourceProvider operations
:vartype custom_resource_provider: azure.mgmt.customproviders.operations.CustomResourceProviderOperations
:ivar associations: Associations operations
:vartype associations: azure.mgmt.customproviders.operations.AssociationsOperations
:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: The Azure subscription ID. This is a
GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000)
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

self.config = CustomProvidersClientConfiguration(credentials, subscription_id, base_url)
super(CustomProvidersClient, self).__init__(self.config.credentials, self.config)

client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
self.api_version = '2018-09-01-preview'
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)

self.operations = Operations(
self._client, self.config, self._serialize, self._deserialize)
self.custom_resource_provider = CustomResourceProviderOperations(
self._client, self.config, self._serialize, self._deserialize)
self.associations = AssociationsOperations(
self._client, self.config, self._serialize, self._deserialize)
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# 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.
# --------------------------------------------------------------------------

try:
from ._models_py3 import Association
from ._models_py3 import CustomRPActionRouteDefinition
from ._models_py3 import CustomRPManifest
from ._models_py3 import CustomRPResourceTypeRouteDefinition
from ._models_py3 import CustomRPRouteDefinition
from ._models_py3 import CustomRPValidations
from ._models_py3 import ErrorDefinition
from ._models_py3 import ErrorResponse, ErrorResponseException
from ._models_py3 import Resource
from ._models_py3 import ResourceProviderOperation
from ._models_py3 import ResourceProviderOperationDisplay
from ._models_py3 import ResourceProvidersUpdate
except (SyntaxError, ImportError):
from ._models import Association
from ._models import CustomRPActionRouteDefinition
from ._models import CustomRPManifest
from ._models import CustomRPResourceTypeRouteDefinition
from ._models import CustomRPRouteDefinition
from ._models import CustomRPValidations
from ._models import ErrorDefinition
from ._models import ErrorResponse, ErrorResponseException
from ._models import Resource
from ._models import ResourceProviderOperation
from ._models import ResourceProviderOperationDisplay
from ._models import ResourceProvidersUpdate
from ._paged_models import AssociationPaged
from ._paged_models import CustomRPManifestPaged
from ._paged_models import ResourceProviderOperationPaged
from ._custom_providers_client_enums import (
ActionRouting,
ResourceTypeRouting,
ValidationType,
ProvisioningState,
)

__all__ = [
'Association',
'CustomRPActionRouteDefinition',
'CustomRPManifest',
'CustomRPResourceTypeRouteDefinition',
'CustomRPRouteDefinition',
'CustomRPValidations',
'ErrorDefinition',
'ErrorResponse', 'ErrorResponseException',
'Resource',
'ResourceProviderOperation',
'ResourceProviderOperationDisplay',
'ResourceProvidersUpdate',
'ResourceProviderOperationPaged',
'CustomRPManifestPaged',
'AssociationPaged',
'ActionRouting',
'ResourceTypeRouting',
'ValidationType',
'ProvisioningState',
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# 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 enum import Enum


class ActionRouting(str, Enum):

proxy = "Proxy"


class ResourceTypeRouting(str, Enum):

proxy = "Proxy"
proxy_cache = "Proxy,Cache"


class ValidationType(str, Enum):

swagger = "Swagger"


class ProvisioningState(str, Enum):

accepted = "Accepted"
deleting = "Deleting"
running = "Running"
succeeded = "Succeeded"
failed = "Failed"
Loading

0 comments on commit 1a3a438

Please sign in to comment.