Skip to content

Commit

Permalink
Merge pull request Azure#932 from lmazuel/search_mgmt
Browse files Browse the repository at this point in the history
azure-mgmt-search 0.1.0
  • Loading branch information
lmazuel authored Dec 23, 2016
2 parents 69da980 + e443872 commit a96ed6e
Show file tree
Hide file tree
Showing 38 changed files with 724 additions and 92 deletions.
1 change: 1 addition & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ listed before.
- azure-mgmt-media 0.1.1
- azure-mgmt-notificationhubs 0.30.0
- azure-mgmt-powerbiembedded 0.30.0rc6
- azure-mgmt-search 0.1.0
- azure-mgmt-servicebus 0.1.0
- azure-mgmt-sql 0.2.0
- azure-mgmt-trafficmanager 0.30.0rc6
Expand Down
9 changes: 9 additions & 0 deletions azure-mgmt-search/HISTORY.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.. :changelog:
Release History
===============

0.1.0 (2016-08-09)
++++++++++++++++++

* Initial Release
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
from .query_key import QueryKey
from .sku import Sku
from .search_service import SearchService
from .search_management_request_options import SearchManagementRequestOptions
from .resource import Resource
from .search_management_request_options import SearchManagementRequestOptions
from .query_key_paged import QueryKeyPaged
from .search_service_paged import SearchServicePaged
from .search_management_client_enums import (
Expand All @@ -35,8 +35,8 @@
'QueryKey',
'Sku',
'SearchService',
'SearchManagementRequestOptions',
'Resource',
'SearchManagementRequestOptions',
'QueryKeyPaged',
'SearchServicePaged',
'UnavailableNameReason',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class AdminKeyResult(Model):
:vartype primary_key: str
:ivar secondary_key: The secondary admin API key of the Search service.
:vartype secondary_key: str
"""
"""

_validation = {
'primary_key': {'readonly': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ class CheckNameAvailabilityInput(Model):
sending a request.
:param name: The Search service name to validate. Search service names
must only contain lowercase letters, digits or dashes, cannot use dash
as the first two or last one characters, cannot contain consecutive
dashes, and must be between 2 and 60 characters in length.
must only contain lowercase letters, digits or dashes, cannot use dash as
the first two or last one characters, cannot contain consecutive dashes,
and must be between 2 and 60 characters in length.
:type name: str
:ivar type: The type of the resource whose name is to be validated. This
value must always be 'searchServices'. Default value: "searchServices" .
:vartype type: str
"""
"""

_validation = {
'name': {'required': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class CheckNameAvailabilityOutput(Model):
provides resource naming requirements. Available only if 'Invalid' is
returned in the 'reason' property.
:vartype message: str
"""
"""

_validation = {
'is_name_available': {'readonly': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class QueryKey(Model):
:vartype name: str
:ivar key: The value of the query API key.
:vartype key: str
"""
"""

_validation = {
'name': {'readonly': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@ class Resource(Model):
Variables are only populated by the server, and will be ignored when
sending a request.
:ivar id: The ID of the resource. This can be used with the Azure
Resource Manager to link resources together.
:ivar id: The ID of the resource. This can be used with the Azure Resource
Manager to link resources together.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The resource type.
:vartype type: str
:param location: The geographic location of the resource. This must be
one of the supported and registered Azure Geo Regions (for example, West
US, East US, Southeast Asia, and so forth).
:param location: The geographic location of the resource. This must be one
of the supported and registered Azure Geo Regions (for example, West US,
East US, Southeast Asia, and so forth).
:type location: str
:param tags: Tags to help categorize the resource in the Azure portal.
:type tags: dict
"""
"""

_validation = {
'id': {'readonly': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ class SearchManagementRequestOptions(Model):
"""Additional parameters for a set of operations.
:param client_request_id: A client-generated GUID value that identifies
this request. If specified, this will be included in response
information as a way to track the request.
this request. If specified, this will be included in response information
as a way to track the request.
:type client_request_id: str
"""
"""

def __init__(self, client_request_id=None):
self.client_request_id = client_request_id
Original file line number Diff line number Diff line change
Expand Up @@ -18,74 +18,71 @@ class SearchService(Resource):
Variables are only populated by the server, and will be ignored when
sending a request.
:ivar id: The ID of the resource. This can be used with the Azure
Resource Manager to link resources together.
:ivar id: The ID of the resource. This can be used with the Azure Resource
Manager to link resources together.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The resource type.
:vartype type: str
:param location: The geographic location of the resource. This must be
one of the supported and registered Azure Geo Regions (for example, West
US, East US, Southeast Asia, and so forth).
:param location: The geographic location of the resource. This must be one
of the supported and registered Azure Geo Regions (for example, West US,
East US, Southeast Asia, and so forth).
:type location: str
:param tags: Tags to help categorize the resource in the Azure portal.
:type tags: dict
:param replica_count: The number of replicas in the Search service. If
specified, it must be a value between 1 and 12 inclusive for standard
SKUs or between 1 and 3 inclusive for basic SKU. Default value: 1 .
specified, it must be a value between 1 and 12 inclusive for standard SKUs
or between 1 and 3 inclusive for basic SKU. Default value: 1 .
:type replica_count: int
:param partition_count: The number of partitions in the Search service;
if specified, it can be 1, 2, 3, 4, 6, or 12. Values greater than 1 are
only valid for standard SKUs. For 'standard3' services with hostingMode
set to 'highDensity', the allowed values are between 1 and 3. Default
value: 1 .
:param partition_count: The number of partitions in the Search service; if
specified, it can be 1, 2, 3, 4, 6, or 12. Values greater than 1 are only
valid for standard SKUs. For 'standard3' services with hostingMode set to
'highDensity', the allowed values are between 1 and 3. Default value: 1 .
:type partition_count: int
:param hosting_mode: Applicable only for the standard3 SKU. You can set
this property to enable up to 3 high density partitions that allow up to
1000 indexes, which is much higher than the maximum indexes allowed for
any other SKU. For the standard3 SKU, the value is either 'default' or
'highDensity'. For all other SKUs, this value must be 'default'.
Possible values include: 'default', 'highDensity'. Default value:
"default" .
'highDensity'. For all other SKUs, this value must be 'default'. Possible
values include: 'default', 'highDensity'. Default value: "default" .
:type hosting_mode: str or :class:`HostingMode
<azure.mgmt.search.models.HostingMode>`
:ivar status: The status of the Search service. Possible values include:
'running': The Search service is running and no provisioning operations
are underway. 'provisioning': The Search service is being provisioned or
scaled up or down. 'deleting': The Search service is being deleted.
'degraded': The Search service is degraded. This can occur when the
underlying search units are not healthy. The Search service is most
likely operational, but performance might be slow and some requests
might be dropped. 'disabled': The Search service is disabled. In this
state, the service will reject all API requests. 'error': The Search
service is in an error state. If your service is in the degraded,
disabled, or error states, it means the Azure Search team is actively
investigating the underlying issue. Dedicated services in these states
are still chargeable based on the number of search units provisioned.
Possible values include: 'running', 'provisioning', 'deleting',
'degraded', 'disabled', 'error'
underlying search units are not healthy. The Search service is most likely
operational, but performance might be slow and some requests might be
dropped. 'disabled': The Search service is disabled. In this state, the
service will reject all API requests. 'error': The Search service is in an
error state. If your service is in the degraded, disabled, or error
states, it means the Azure Search team is actively investigating the
underlying issue. Dedicated services in these states are still chargeable
based on the number of search units provisioned. Possible values include:
'running', 'provisioning', 'deleting', 'degraded', 'disabled', 'error'
:vartype status: str or :class:`SearchServiceStatus
<azure.mgmt.search.models.SearchServiceStatus>`
:ivar status_details: The details of the Search service status.
:vartype status_details: str
:ivar provisioning_state: The state of the last provisioning operation
performed on the Search service. Provisioning is an intermediate state
that occurs while service capacity is being established. After capacity
is set up, provisioningState changes to either 'succeeded' or 'failed'.
Client applications can poll provisioning status (the recommended
polling interval is from 30 seconds to one minute) by using the Get
Search Service operation to see when an operation is completed. If you
are using the free service, this value tends to come back as 'succeeded'
directly in the call to Create Search service. This is because the free
service uses capacity that is already set up. Possible values include:
'succeeded', 'provisioning', 'failed'
that occurs while service capacity is being established. After capacity is
set up, provisioningState changes to either 'succeeded' or 'failed'.
Client applications can poll provisioning status (the recommended polling
interval is from 30 seconds to one minute) by using the Get Search Service
operation to see when an operation is completed. If you are using the free
service, this value tends to come back as 'succeeded' directly in the call
to Create Search service. This is because the free service uses capacity
that is already set up. Possible values include: 'succeeded',
'provisioning', 'failed'
:vartype provisioning_state: str or :class:`ProvisioningState
<azure.mgmt.search.models.ProvisioningState>`
:param sku: The SKU of the Search Service, which determines price tier
and capacity limits.
:param sku: The SKU of the Search Service, which determines price tier and
capacity limits.
:type sku: :class:`Sku <azure.mgmt.search.models.Sku>`
"""
"""

_validation = {
'id': {'readonly': True},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,19 @@


class Sku(Model):
"""Defines the SKU of an Azure Search Service, which determines price tier
and capacity limits.
"""Defines the SKU of an Azure Search Service, which determines price tier and
capacity limits.
:param name: The SKU of the Search service. Valid values include: 'free':
Shared service. 'basic': Dedicated service with up to 3 replicas.
'standard': Dedicated service with up to 12 partitions and 12 replicas.
'standard2': Similar to standard, but with more capacity per search
unit. 'standard3': Offers maximum capacity per search unit with up to 12
partitions and 12 replicas (or up to 3 partitions with more indexes if
you also set the hostingMode property to 'highDensity'). Possible values
'standard2': Similar to standard, but with more capacity per search unit.
'standard3': Offers maximum capacity per search unit with up to 12
partitions and 12 replicas (or up to 3 partitions with more indexes if you
also set the hostingMode property to 'highDensity'). Possible values
include: 'free', 'basic', 'standard', 'standard2', 'standard3'
:type name: str or :class:`SkuName <azure.mgmt.search.models.SkuName>`
"""
"""

_attribute_map = {
'name': {'key': 'name', 'type': 'SkuName'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ def get(

def regenerate(
self, resource_group_name, search_service_name, key_kind, search_management_request_options=None, custom_headers=None, raw=False, **operation_config):
"""Regenerates either the primary or secondary admin API key. You can
only regenerate one key at a time.
"""Regenerates either the primary or secondary admin API key. You can only
regenerate one key at a time.
:param resource_group_name: The name of the resource group within the
current subscription. You can obtain this value from the Azure
Expand All @@ -123,8 +123,8 @@ def regenerate(
associated with the specified resource group.
:type search_service_name: str
:param key_kind: Specifies which key to regenerate. Valid values
include 'primary' and 'secondary'. Possible values include:
'primary', 'secondary'
include 'primary' and 'secondary'. Possible values include: 'primary',
'secondary'
:type key_kind: str or :class:`AdminKeyKind
<azure.mgmt.search.models.AdminKeyKind>`
:param search_management_request_options: Additional parameters for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,8 @@ def internal_paging(next_link=None, raw=False):
def delete(
self, resource_group_name, search_service_name, key, search_management_request_options=None, custom_headers=None, raw=False, **operation_config):
"""Deletes the specified query key. Unlike admin keys, query keys are not
regenerated. The process for regenerating a query key is to delete
and then recreate it.
regenerated. The process for regenerating a query key is to delete and
then recreate it.
:param resource_group_name: The name of the resource group within the
current subscription. You can obtain this value from the Azure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ def __init__(self, client, config, serializer, deserializer):

def create_or_update(
self, resource_group_name, search_service_name, service, search_management_request_options=None, custom_headers=None, raw=False, **operation_config):
"""Creates or updates a Search service in the given resource group. If
the Search service already exists, all properties will be updated
with the given values.
"""Creates or updates a Search service in the given resource group. If the
Search service already exists, all properties will be updated with the
given values.
:param resource_group_name: The name of the resource group within the
current subscription. You can obtain this value from the Azure
Expand All @@ -46,9 +46,9 @@ def create_or_update(
:param search_service_name: The name of the Azure Search service to
create or update. Search service names must only contain lowercase
letters, digits or dashes, cannot use dash as the first two or last
one characters, cannot contain consecutive dashes, and must be
between 2 and 60 characters in length. Search service names must be
globally unique since they are part of the service URI
one characters, cannot contain consecutive dashes, and must be between
2 and 60 characters in length. Search service names must be globally
unique since they are part of the service URI
(https://<name>.search.windows.net). You cannot change the service
name after the service is created.
:type search_service_name: str
Expand Down Expand Up @@ -358,11 +358,10 @@ def check_name_availability(
use. Search service names must be globally unique since they are part
of the service URI (https://<name>.search.windows.net).
:param name: The Search service name to validate. Search service
names must only contain lowercase letters, digits or dashes, cannot
use dash as the first two or last one characters, cannot contain
consecutive dashes, and must be between 2 and 60 characters in
length.
:param name: The Search service name to validate. Search service names
must only contain lowercase letters, digits or dashes, cannot use dash
as the first two or last one characters, cannot contain consecutive
dashes, and must be between 2 and 60 characters in length.
:type name: str
:param search_management_request_options: Additional parameters for
the operation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
# regenerated.
# --------------------------------------------------------------------------

VERSION = "0.30.0rc6"
VERSION = "0.1.0"

File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
# license information.
#--------------------------------------------------------------------------

from setuptools import setup
from setuptools import find_packages, setup
from io import open
import re

# azure v0.x is not compatible with this package
Expand All @@ -32,11 +33,16 @@
if not version:
raise RuntimeError('Cannot find version information')

with open('README.rst', encoding='utf-8') as f:
readme = f.read()
with open('HISTORY.rst', encoding='utf-8') as f:
history = f.read()

setup(
name='azure-mgmt-search',
version=version,
description='Microsoft Azure Search Management Client Library for Python',
long_description=open('README.rst', 'r').read(),
long_description=readme + '\n\n' + history,
license='MIT License',
author='Microsoft Corporation',
author_email='[email protected]',
Expand All @@ -53,15 +59,10 @@
'License :: OSI Approved :: MIT License',
],
zip_safe=False,
packages=[
'azure',
'azure.mgmt',
'azure.mgmt.search',
'azure.mgmt.search.models',
'azure.mgmt.search.operations',
],
packages=find_packages(),
install_requires=[
'azure-common[autorest]==1.1.4',
'msrestazure~=0.4.6',
'azure-common~=1.1.4',
'azure-mgmt-nspkg',
],
)
Loading

0 comments on commit a96ed6e

Please sign in to comment.