Skip to content

Commit 433a737

Browse files
[AutoRelease] t2-search-2025-02-17-53579(can only be merged by SDK owner) (#39766)
* code and test * update testcases * Update release date in CHANGELOG.md * update testcases --------- Co-authored-by: azure-sdk <PythonSdkPipelines> Co-authored-by: ChenxiJiang333 <[email protected]> Co-authored-by: ChenxiJiang333 <[email protected]>
1 parent b87fc53 commit 433a737

File tree

128 files changed

+3940
-849
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

128 files changed

+3940
-849
lines changed

sdk/search/azure-mgmt-search/CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# Release History
22

3+
## 9.2.0b3 (2025-03-24)
4+
5+
### Features Added
6+
7+
- Client `SearchManagementClient` added operation group `offerings`
8+
- Client `SearchManagementClient` added operation group `service`
9+
- Model `SearchService` added property `system_data`
10+
- Model `SearchService` added property `endpoint`
11+
- Model `SearchService` added property `compute_type`
12+
- Model `SearchService` added property `upgrade_available`
13+
- Model `SearchService` added property `service_upgrade_date`
14+
- Model `SearchServiceUpdate` added property `system_data`
15+
- Model `SearchServiceUpdate` added property `endpoint`
16+
- Model `SearchServiceUpdate` added property `compute_type`
17+
- Model `SearchServiceUpdate` added property `upgrade_available`
18+
- Model `SearchServiceUpdate` added property `service_upgrade_date`
19+
- Added enum `ComputeType`
20+
- Added enum `CreatedByType`
21+
- Added enum `FeatureName`
22+
- Added model `FeatureOffering`
23+
- Added model `OfferingsByRegion`
24+
- Added model `OfferingsListResult`
25+
- Added model `SkuOffering`
26+
- Added model `SkuOfferingLimits`
27+
- Added model `SystemData`
28+
- Added operation group `OfferingsOperations`
29+
- Added operation group `ServiceOperations`
30+
331
## 9.2.0b2 (2024-07-18)
432

533
### Other Changes
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"commit": "32f566eb38af9593cfc1ed183362471c50d67fb2",
2+
"commit": "f6674831693bce0982f08ccf356255248a4c9a8f",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
44
"autorest": "3.10.2",
55
"use": [
6-
"@autorest/python@6.13.16",
6+
"@autorest/python@6.27.4",
77
"@autorest/[email protected]"
88
],
9-
"autorest_command": "autorest specification/search/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.13.16 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
9+
"autorest_command": "autorest specification/search/resource-manager/readme.md --generate-sample=True --generate-test=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.27.4 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
1010
"readme": "specification/search/resource-manager/readme.md"
1111
}

sdk/search/azure-mgmt-search/assets.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

sdk/search/azure-mgmt-search/azure/mgmt/search/__init__.py

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,28 @@
55
# Code generated by Microsoft (R) AutoRest Code Generator.
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
8+
# pylint: disable=wrong-import-position
89

9-
from ._search_management_client import SearchManagementClient
10+
from typing import TYPE_CHECKING
11+
12+
if TYPE_CHECKING:
13+
from ._patch import * # pylint: disable=unused-wildcard-import
14+
15+
from ._search_management_client import SearchManagementClient # type: ignore
1016
from ._version import VERSION
1117

1218
__version__ = VERSION
1319

1420
try:
1521
from ._patch import __all__ as _patch_all
16-
from ._patch import * # pylint: disable=unused-wildcard-import
22+
from ._patch import *
1723
except ImportError:
1824
_patch_all = []
1925
from ._patch import patch_sdk as _patch_sdk
2026

2127
__all__ = [
2228
"SearchManagementClient",
2329
]
24-
__all__.extend([p for p in _patch_all if p not in __all__])
30+
__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore
2531

2632
_patch_sdk()

sdk/search/azure-mgmt-search/azure/mgmt/search/_configuration.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@
1414
from ._version import VERSION
1515

1616
if TYPE_CHECKING:
17-
# pylint: disable=unused-import,ungrouped-imports
1817
from azure.core.credentials import TokenCredential
1918

2019

21-
class SearchManagementClientConfiguration: # pylint: disable=too-many-instance-attributes,name-too-long
20+
class SearchManagementClientConfiguration: # pylint: disable=too-many-instance-attributes
2221
"""Configuration for SearchManagementClient.
2322
2423
Note that all parameters used to create this instance are saved as instance
@@ -29,13 +28,13 @@ class SearchManagementClientConfiguration: # pylint: disable=too-many-instance-
2928
:param subscription_id: The unique identifier for a Microsoft Azure subscription. You can
3029
obtain this value from the Azure Resource Manager API or the portal. Required.
3130
:type subscription_id: str
32-
:keyword api_version: Api Version. Default value is "2024-06-01-preview". Note that overriding
31+
:keyword api_version: Api Version. Default value is "2025-02-01-preview". Note that overriding
3332
this default value may result in unsupported behavior.
3433
:paramtype api_version: str
3534
"""
3635

3736
def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
38-
api_version: str = kwargs.pop("api_version", "2024-06-01-preview")
37+
api_version: str = kwargs.pop("api_version", "2025-02-01-preview")
3938

4039
if credential is None:
4140
raise ValueError("Parameter 'credential' must not be None.")

sdk/search/azure-mgmt-search/azure/mgmt/search/_search_management_client.py

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
from copy import deepcopy
1010
from typing import Any, TYPE_CHECKING
11+
from typing_extensions import Self
1112

1213
from azure.core.pipeline import policies
1314
from azure.core.rest import HttpRequest, HttpResponse
@@ -20,28 +21,29 @@
2021
from .operations import (
2122
AdminKeysOperations,
2223
NetworkSecurityPerimeterConfigurationsOperations,
24+
OfferingsOperations,
2325
Operations,
2426
PrivateEndpointConnectionsOperations,
2527
PrivateLinkResourcesOperations,
2628
QueryKeysOperations,
2729
SearchManagementClientOperationsMixin,
30+
ServiceOperations,
2831
ServicesOperations,
2932
SharedPrivateLinkResourcesOperations,
3033
UsagesOperations,
3134
)
3235

3336
if TYPE_CHECKING:
34-
# pylint: disable=unused-import,ungrouped-imports
3537
from azure.core.credentials import TokenCredential
3638

3739

38-
class SearchManagementClient(
39-
SearchManagementClientOperationsMixin
40-
): # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
40+
class SearchManagementClient(SearchManagementClientOperationsMixin): # pylint: disable=too-many-instance-attributes
4141
"""Client that can be used to manage Azure AI Search services and API keys.
4242
4343
:ivar operations: Operations operations
4444
:vartype operations: azure.mgmt.search.operations.Operations
45+
:ivar offerings: OfferingsOperations operations
46+
:vartype offerings: azure.mgmt.search.operations.OfferingsOperations
4547
:ivar admin_keys: AdminKeysOperations operations
4648
:vartype admin_keys: azure.mgmt.search.operations.AdminKeysOperations
4749
:ivar query_keys: QueryKeysOperations operations
@@ -62,14 +64,16 @@ class SearchManagementClient(
6264
NetworkSecurityPerimeterConfigurationsOperations operations
6365
:vartype network_security_perimeter_configurations:
6466
azure.mgmt.search.operations.NetworkSecurityPerimeterConfigurationsOperations
67+
:ivar service: ServiceOperations operations
68+
:vartype service: azure.mgmt.search.operations.ServiceOperations
6569
:param credential: Credential needed for the client to connect to Azure. Required.
6670
:type credential: ~azure.core.credentials.TokenCredential
6771
:param subscription_id: The unique identifier for a Microsoft Azure subscription. You can
6872
obtain this value from the Azure Resource Manager API or the portal. Required.
6973
:type subscription_id: str
7074
:param base_url: Service URL. Default value is "https://management.azure.com".
7175
:type base_url: str
72-
:keyword api_version: Api Version. Default value is "2024-06-01-preview". Note that overriding
76+
:keyword api_version: Api Version. Default value is "2025-02-01-preview". Note that overriding
7377
this default value may result in unsupported behavior.
7478
:paramtype api_version: str
7579
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
@@ -111,6 +115,7 @@ def __init__(
111115
self._deserialize = Deserializer(client_models)
112116
self._serialize.client_side_validation = False
113117
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
118+
self.offerings = OfferingsOperations(self._client, self._config, self._serialize, self._deserialize)
114119
self.admin_keys = AdminKeysOperations(self._client, self._config, self._serialize, self._deserialize)
115120
self.query_keys = QueryKeysOperations(self._client, self._config, self._serialize, self._deserialize)
116121
self.services = ServicesOperations(self._client, self._config, self._serialize, self._deserialize)
@@ -127,6 +132,7 @@ def __init__(
127132
self.network_security_perimeter_configurations = NetworkSecurityPerimeterConfigurationsOperations(
128133
self._client, self._config, self._serialize, self._deserialize
129134
)
135+
self.service = ServiceOperations(self._client, self._config, self._serialize, self._deserialize)
130136

131137
def _send_request(self, request: HttpRequest, *, stream: bool = False, **kwargs: Any) -> HttpResponse:
132138
"""Runs the network request through the client's chained policies.
@@ -153,7 +159,7 @@ def _send_request(self, request: HttpRequest, *, stream: bool = False, **kwargs:
153159
def close(self) -> None:
154160
self._client.close()
155161

156-
def __enter__(self) -> "SearchManagementClient":
162+
def __enter__(self) -> Self:
157163
self._client.__enter__()
158164
return self
159165

0 commit comments

Comments
 (0)