Skip to content

Commit 0c7a2aa

Browse files
msyycAutorestCIBigCat20196
authored
[synapse-artifacts] release for composite-v5 (Azure#26170)
* code * update * Packaging update of azure-synapse-artifacts * update * Packaging update of azure-synapse-artifacts * update dependency for ci * changelog * Packaging update of azure-synapse-artifacts * update * Update _version.py * test * Update CHANGELOG.md * Update CHANGELOG.md Co-authored-by: Azure SDK Bot <[email protected]> Co-authored-by: Jiefeng Chen (WICRESOFT NORTH AMERICA LTD) <[email protected]>
1 parent 56f5beb commit 0c7a2aa

File tree

75 files changed

+37517
-31851
lines changed

Some content is hidden

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

75 files changed

+37517
-31851
lines changed

sdk/synapse/azure-synapse-artifacts/CHANGELOG.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# Release History
22

3-
## 0.13.1 (Unreleased)
3+
## 0.14.0 (2022-09-19)
44

55
### Features Added
66

7-
### Breaking Changes
8-
9-
### Bugs Fixed
7+
- Upgraded api-version for some operation group
108

119
### Other Changes
10+
11+
- Drop support for python3.6
1212

1313
## 0.13.0 (2022-04-21)
1414

sdk/synapse/azure-synapse-artifacts/LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1818
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1919
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
21+
SOFTWARE.
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
recursive-include tests *.py *.yaml
1+
include _meta.json
2+
recursive-include tests *.py *.json
23
recursive-include samples *.py *.md
34
include *.md
4-
include LICENSE
55
include azure/__init__.py
66
include azure/synapse/__init__.py
7+
include LICENSE
78
include azure/synapse/artifacts/py.typed

sdk/synapse/azure-synapse-artifacts/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Microsoft Azure SDK for Python
22

33
This is the Microsoft Azure Synapse Artifacts Client Library.
4-
This package has been tested with Python 3.6, 3.7, 3.8, 3.9 and 3.10.
4+
This package has been tested with Python 3.7+.
55
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).
66

77
## _Disclaimer_
@@ -16,6 +16,7 @@ For code examples, see [Synapse Artifacts](https://docs.microsoft.com/python/api
1616

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

2122
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-synapse-artifacts%2FREADME.png)
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
1+
__path__ = __import__("pkgutil").extend_path(__path__, __name__)
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
1+
__path__ = __import__("pkgutil").extend_path(__path__, __name__)

sdk/synapse/azure-synapse-artifacts/azure/synapse/artifacts/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717
except ImportError:
1818
_patch_all = []
1919
from ._patch import patch_sdk as _patch_sdk
20-
__all__ = ['ArtifactsClient']
20+
21+
__all__ = ["ArtifactsClient"]
2122
__all__.extend([p for p in _patch_all if p not in __all__])
2223

2324
_patch_sdk()

sdk/synapse/azure-synapse-artifacts/azure/synapse/artifacts/_artifacts_client.py

Lines changed: 53 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,44 @@
99
from copy import deepcopy
1010
from typing import Any, TYPE_CHECKING
1111

12-
from msrest import Deserializer, Serializer
13-
1412
from azure.core import PipelineClient
1513
from azure.core.rest import HttpRequest, HttpResponse
1614

1715
from . import models
1816
from ._configuration import ArtifactsClientConfiguration
19-
from .operations import BigDataPoolsOperations, DataFlowDebugSessionOperations, DataFlowOperations, DatasetOperations, IntegrationRuntimesOperations, KqlScriptOperations, KqlScriptsOperations, LibraryOperations, LinkConnectionOperations, LinkedServiceOperations, MetastoreOperations, NotebookOperationResultOperations, NotebookOperations, PipelineOperations, PipelineRunOperations, SparkConfigurationOperations, SparkJobDefinitionOperations, SqlPoolsOperations, SqlScriptOperations, TriggerOperations, TriggerRunOperations, WorkspaceGitRepoManagementOperations, WorkspaceOperations
17+
from ._serialization import Deserializer, Serializer
18+
from .operations import (
19+
BigDataPoolsOperations,
20+
DataFlowDebugSessionOperations,
21+
DataFlowOperations,
22+
DatasetOperations,
23+
IntegrationRuntimesOperations,
24+
KqlScriptOperations,
25+
KqlScriptsOperations,
26+
LibraryOperations,
27+
LinkConnectionOperations,
28+
LinkedServiceOperations,
29+
MetastoreOperations,
30+
NotebookOperationResultOperations,
31+
NotebookOperations,
32+
PipelineOperations,
33+
PipelineRunOperations,
34+
SparkConfigurationOperations,
35+
SparkJobDefinitionOperations,
36+
SqlPoolsOperations,
37+
SqlScriptOperations,
38+
TriggerOperations,
39+
TriggerRunOperations,
40+
WorkspaceGitRepoManagementOperations,
41+
WorkspaceOperations,
42+
)
2043

2144
if TYPE_CHECKING:
2245
# pylint: disable=unused-import,ungrouped-imports
2346
from azure.core.credentials import TokenCredential
2447

25-
class ArtifactsClient: # pylint: disable=too-many-instance-attributes
48+
49+
class ArtifactsClient: # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
2650
"""ArtifactsClient.
2751
2852
:ivar link_connection: LinkConnectionOperations operations
@@ -74,105 +98,61 @@ class ArtifactsClient: # pylint: disable=too-many-instance-attributes
7498
:vartype trigger_run: azure.synapse.artifacts.operations.TriggerRunOperations
7599
:ivar workspace: WorkspaceOperations operations
76100
:vartype workspace: azure.synapse.artifacts.operations.WorkspaceOperations
77-
:param credential: Credential needed for the client to connect to Azure.
101+
:param credential: Credential needed for the client to connect to Azure. Required.
78102
:type credential: ~azure.core.credentials.TokenCredential
79103
:param endpoint: The workspace development endpoint, for example
80-
https://myworkspace.dev.azuresynapse.net.
104+
https://myworkspace.dev.azuresynapse.net. Required.
81105
:type endpoint: str
82106
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
83107
Retry-After header is present.
84108
"""
85109

86-
def __init__(
87-
self,
88-
credential: "TokenCredential",
89-
endpoint: str,
90-
**kwargs: Any
91-
) -> None:
92-
_base_url = '{endpoint}'
110+
def __init__(self, credential: "TokenCredential", endpoint: str, **kwargs: Any) -> None:
111+
_endpoint = "{endpoint}"
93112
self._config = ArtifactsClientConfiguration(credential=credential, endpoint=endpoint, **kwargs)
94-
self._client = PipelineClient(base_url=_base_url, config=self._config, **kwargs)
113+
self._client = PipelineClient(base_url=_endpoint, config=self._config, **kwargs)
95114

96115
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
97116
self._serialize = Serializer(client_models)
98117
self._deserialize = Deserializer(client_models)
99118
self._serialize.client_side_validation = False
100-
self.link_connection = LinkConnectionOperations(
101-
self._client, self._config, self._serialize, self._deserialize
102-
)
103-
self.kql_scripts = KqlScriptsOperations(
104-
self._client, self._config, self._serialize, self._deserialize
105-
)
106-
self.kql_script = KqlScriptOperations(
107-
self._client, self._config, self._serialize, self._deserialize
108-
)
109-
self.metastore = MetastoreOperations(
110-
self._client, self._config, self._serialize, self._deserialize
111-
)
119+
self.link_connection = LinkConnectionOperations(self._client, self._config, self._serialize, self._deserialize)
120+
self.kql_scripts = KqlScriptsOperations(self._client, self._config, self._serialize, self._deserialize)
121+
self.kql_script = KqlScriptOperations(self._client, self._config, self._serialize, self._deserialize)
122+
self.metastore = MetastoreOperations(self._client, self._config, self._serialize, self._deserialize)
112123
self.spark_configuration = SparkConfigurationOperations(
113124
self._client, self._config, self._serialize, self._deserialize
114125
)
115-
self.big_data_pools = BigDataPoolsOperations(
116-
self._client, self._config, self._serialize, self._deserialize
117-
)
118-
self.data_flow = DataFlowOperations(
119-
self._client, self._config, self._serialize, self._deserialize
120-
)
126+
self.big_data_pools = BigDataPoolsOperations(self._client, self._config, self._serialize, self._deserialize)
127+
self.data_flow = DataFlowOperations(self._client, self._config, self._serialize, self._deserialize)
121128
self.data_flow_debug_session = DataFlowDebugSessionOperations(
122129
self._client, self._config, self._serialize, self._deserialize
123130
)
124-
self.dataset = DatasetOperations(
125-
self._client, self._config, self._serialize, self._deserialize
126-
)
131+
self.dataset = DatasetOperations(self._client, self._config, self._serialize, self._deserialize)
127132
self.workspace_git_repo_management = WorkspaceGitRepoManagementOperations(
128133
self._client, self._config, self._serialize, self._deserialize
129134
)
130135
self.integration_runtimes = IntegrationRuntimesOperations(
131136
self._client, self._config, self._serialize, self._deserialize
132137
)
133-
self.library = LibraryOperations(
134-
self._client, self._config, self._serialize, self._deserialize
135-
)
136-
self.linked_service = LinkedServiceOperations(
137-
self._client, self._config, self._serialize, self._deserialize
138-
)
139-
self.notebook = NotebookOperations(
140-
self._client, self._config, self._serialize, self._deserialize
141-
)
138+
self.library = LibraryOperations(self._client, self._config, self._serialize, self._deserialize)
139+
self.linked_service = LinkedServiceOperations(self._client, self._config, self._serialize, self._deserialize)
140+
self.notebook = NotebookOperations(self._client, self._config, self._serialize, self._deserialize)
142141
self.notebook_operation_result = NotebookOperationResultOperations(
143142
self._client, self._config, self._serialize, self._deserialize
144143
)
145-
self.pipeline = PipelineOperations(
146-
self._client, self._config, self._serialize, self._deserialize
147-
)
148-
self.pipeline_run = PipelineRunOperations(
149-
self._client, self._config, self._serialize, self._deserialize
150-
)
144+
self.pipeline = PipelineOperations(self._client, self._config, self._serialize, self._deserialize)
145+
self.pipeline_run = PipelineRunOperations(self._client, self._config, self._serialize, self._deserialize)
151146
self.spark_job_definition = SparkJobDefinitionOperations(
152147
self._client, self._config, self._serialize, self._deserialize
153148
)
154-
self.sql_pools = SqlPoolsOperations(
155-
self._client, self._config, self._serialize, self._deserialize
156-
)
157-
self.sql_script = SqlScriptOperations(
158-
self._client, self._config, self._serialize, self._deserialize
159-
)
160-
self.trigger = TriggerOperations(
161-
self._client, self._config, self._serialize, self._deserialize
162-
)
163-
self.trigger_run = TriggerRunOperations(
164-
self._client, self._config, self._serialize, self._deserialize
165-
)
166-
self.workspace = WorkspaceOperations(
167-
self._client, self._config, self._serialize, self._deserialize
168-
)
169-
149+
self.sql_pools = SqlPoolsOperations(self._client, self._config, self._serialize, self._deserialize)
150+
self.sql_script = SqlScriptOperations(self._client, self._config, self._serialize, self._deserialize)
151+
self.trigger = TriggerOperations(self._client, self._config, self._serialize, self._deserialize)
152+
self.trigger_run = TriggerRunOperations(self._client, self._config, self._serialize, self._deserialize)
153+
self.workspace = WorkspaceOperations(self._client, self._config, self._serialize, self._deserialize)
170154

171-
def _send_request(
172-
self,
173-
request: HttpRequest,
174-
**kwargs: Any
175-
) -> HttpResponse:
155+
def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
176156
"""Runs the network request through the client's chained policies.
177157
178158
>>> from azure.core.rest import HttpRequest
@@ -181,7 +161,7 @@ def _send_request(
181161
>>> response = client._send_request(request)
182162
<HttpResponse: 200 OK>
183163
184-
For more information on this code flow, see https://aka.ms/azsdk/python/protocol/quickstart
164+
For more information on this code flow, see https://aka.ms/azsdk/dpcodegen/python/send_request
185165
186166
:param request: The network request you want to make. Required.
187167
:type request: ~azure.core.rest.HttpRequest
@@ -192,7 +172,7 @@ def _send_request(
192172

193173
request_copy = deepcopy(request)
194174
path_format_arguments = {
195-
"endpoint": self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True),
175+
"endpoint": self._serialize.url("self._config.endpoint", self._config.endpoint, "str", skip_quote=True),
196176
}
197177

198178
request_copy.url = self._client.format_url(request_copy.url, **path_format_arguments)

sdk/synapse/azure-synapse-artifacts/azure/synapse/artifacts/_configuration.py

Lines changed: 18 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -24,19 +24,14 @@ class ArtifactsClientConfiguration(Configuration): # pylint: disable=too-many-i
2424
Note that all parameters used to create this instance are saved as instance
2525
attributes.
2626
27-
:param credential: Credential needed for the client to connect to Azure.
27+
:param credential: Credential needed for the client to connect to Azure. Required.
2828
:type credential: ~azure.core.credentials.TokenCredential
2929
:param endpoint: The workspace development endpoint, for example
30-
https://myworkspace.dev.azuresynapse.net.
30+
https://myworkspace.dev.azuresynapse.net. Required.
3131
:type endpoint: str
3232
"""
3333

34-
def __init__(
35-
self,
36-
credential: "TokenCredential",
37-
endpoint: str,
38-
**kwargs: Any
39-
) -> None:
34+
def __init__(self, credential: "TokenCredential", endpoint: str, **kwargs: Any) -> None:
4035
super(ArtifactsClientConfiguration, self).__init__(**kwargs)
4136
if credential is None:
4237
raise ValueError("Parameter 'credential' must not be None.")
@@ -45,23 +40,24 @@ def __init__(
4540

4641
self.credential = credential
4742
self.endpoint = endpoint
48-
self.credential_scopes = kwargs.pop('credential_scopes', ['https://dev.azuresynapse.net/.default'])
49-
kwargs.setdefault('sdk_moniker', 'synapse-artifacts/{}'.format(VERSION))
43+
self.credential_scopes = kwargs.pop("credential_scopes", ["https://dev.azuresynapse.net/.default"])
44+
kwargs.setdefault("sdk_moniker", "synapse-artifacts/{}".format(VERSION))
5045
self._configure(**kwargs)
5146

5247
def _configure(
53-
self,
54-
**kwargs # type: Any
48+
self, **kwargs # type: Any
5549
):
5650
# type: (...) -> None
57-
self.user_agent_policy = kwargs.get('user_agent_policy') or policies.UserAgentPolicy(**kwargs)
58-
self.headers_policy = kwargs.get('headers_policy') or policies.HeadersPolicy(**kwargs)
59-
self.proxy_policy = kwargs.get('proxy_policy') or policies.ProxyPolicy(**kwargs)
60-
self.logging_policy = kwargs.get('logging_policy') or policies.NetworkTraceLoggingPolicy(**kwargs)
61-
self.http_logging_policy = kwargs.get('http_logging_policy') or policies.HttpLoggingPolicy(**kwargs)
62-
self.retry_policy = kwargs.get('retry_policy') or policies.RetryPolicy(**kwargs)
63-
self.custom_hook_policy = kwargs.get('custom_hook_policy') or policies.CustomHookPolicy(**kwargs)
64-
self.redirect_policy = kwargs.get('redirect_policy') or policies.RedirectPolicy(**kwargs)
65-
self.authentication_policy = kwargs.get('authentication_policy')
51+
self.user_agent_policy = kwargs.get("user_agent_policy") or policies.UserAgentPolicy(**kwargs)
52+
self.headers_policy = kwargs.get("headers_policy") or policies.HeadersPolicy(**kwargs)
53+
self.proxy_policy = kwargs.get("proxy_policy") or policies.ProxyPolicy(**kwargs)
54+
self.logging_policy = kwargs.get("logging_policy") or policies.NetworkTraceLoggingPolicy(**kwargs)
55+
self.http_logging_policy = kwargs.get("http_logging_policy") or policies.HttpLoggingPolicy(**kwargs)
56+
self.retry_policy = kwargs.get("retry_policy") or policies.RetryPolicy(**kwargs)
57+
self.custom_hook_policy = kwargs.get("custom_hook_policy") or policies.CustomHookPolicy(**kwargs)
58+
self.redirect_policy = kwargs.get("redirect_policy") or policies.RedirectPolicy(**kwargs)
59+
self.authentication_policy = kwargs.get("authentication_policy")
6660
if self.credential and not self.authentication_policy:
67-
self.authentication_policy = policies.BearerTokenCredentialPolicy(self.credential, *self.credential_scopes, **kwargs)
61+
self.authentication_policy = policies.BearerTokenCredentialPolicy(
62+
self.credential, *self.credential_scopes, **kwargs
63+
)

sdk/synapse/azure-synapse-artifacts/azure/synapse/artifacts/_patch.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,4 @@
2828
# This file is used for handwritten extensions to the generated code. Example:
2929
# https://github.com/Azure/azure-sdk-for-python/blob/main/doc/dev/customize_code/how-to-patch-sdk-code.md
3030
def patch_sdk():
31-
pass
31+
pass

0 commit comments

Comments
 (0)