Skip to content

Commit e8f09d0

Browse files
AutorestCIlmazuel
authored andcommitted
[AutoPR] compute/resource-manager (#2487)
* Generated from c0def97e9fc1e839db7727fd31c2f583f6cf04d6 (#2486) updated OS Upgrade History API (cherry picked from commit e784ecac207c88dda10fa0986609907486994913) * Generated from 8fe96075f82faeec0c0e316e0dd1a1c0ee77e376 (#2501) fixed formatting * [AutoPR compute/resource-manager] added autoOSUpgradePolicy to UpgradePolicy (#2505) * Generated from 57e4037bd66b30a7f95fda331085521b2d669c94 added autoOSUpgradePolicy * Generated from 27752fd2417b688d4aba3bcde1ada9231659d208 added deafult value as false * Generated from 27752fd2417b688d4aba3bcde1ada9231659d208 added deafult value as false * Generated from 87e0684ac67bc015bf82c1f1227093265c2e1233 (#2562) added older examples * Generated from 7014b952af241255afcf4e2b620cfd40737a3ea1 (#2580) Upgrade Compute API version to 2018-04-01 and Fix the response of all POST operation. * [AutoPR compute/resource-manager] Added the swagger file for the new service Gallery. (#2563) * Generated from b48862551b5e97eb40acb3da63e55522a9db566c Added the swagger file for the new service Gallery. * Generated from d2537a58b0496d8860759d47a9c344c19d217995 Gallery Python conf * Generated from 29d0c5762aad64243a021fac44d65b8610304e4e Fixed description for 202 response. * Generated from 29d0c5762aad64243a021fac44d65b8610304e4e Fixed description for 202 response. * Generated from b74f3ee0fdca928bf92a7fdd2bcd17994deadca9 Changed the operationId to conform to naming convention. * Generated from 664c041aeed346e4fdc3a2c8c29c1c59e7505b66 Fixed some typos. * Generated from e7ab96432e0bfc7c49839ca5d1194ec1be0c23a9 Add default error response. Make provisioningInfo a enum type. * Generated from c26feda2acff5be97893b6e5db4270e09dbf1c25 Fixed comments according to CR. * Generated from b757a4ec5fd9e1a35bedefd53fe3d92e111db5eb Resolved merge conflicts. * Generated from 4abedb1c096796557fdd029401f3d317f99c7f61 (#2664) removing resourceUpdate, adding contents to disk and snapshot * Generated from a2f275e122829ab63c18494dbaae5a1e9ef6e81c (#2673) Compute Py conf * [AutoPR compute/resource-manager] [Compute] Fix List VM Extension API name, description updates and other fixes. (#2677) * Generated from e1a86d44e0c41fe932513a0d2c96c0852c382aa0 Fix List VM Extension API name, description updates and fix for 2018-06-01 version * Generated from d4855e2ca85a8ed773644fdb69da2a852097cca4 Add VMSS Ip Tag * Generated from d4855e2ca85a8ed773644fdb69da2a852097cca4 Add VMSS Ip Tag * Rebuild by #2487 * Generated from 41175e4e605bb5ed0329cdfa91ae14cfbd6a6739 (#2829) Addressed comments - added missing StandardSSD_LRS in 2018-04-01, updated name to ListAll, and removed the change from 2015-06-15 * Generated from 0a9ee3a2db06dff212c23f80c8b7bf1eec31613a (#2858) User identities in a new dictionary property Moving user identities support from the property "identityId" list to a new dictionary property named "userAssignedIdentities". * Generated from c34f1fdacb2efacd4dccdd69213e83e4800ab76a (#2859) Added listing all availability sets in a subscription and StandardSSD_LRS to 2018-06-01 * Generated from d4e9a10c23b602709da6ec04f970c7802ca60af3 (#2886) Got the latest code from official repo master branch and resolved the conflicts. * Rebuild by #2487 * Update version.py * Generated from 0e3b2e2f19773ecc8bb676f2d40cff4119b2a357 (#2890) Python conf for Compute 2018-06 * [AutoPR compute/resource-manager] Update RunCommand operation output as valid json object (#2888) * Generated from e3d9ca01eb41c555b03705a38e58173de2196194 Update RunCommand operation output as valid json object * Generated from e3d9ca01eb41c555b03705a38e58173de2196194 Update RunCommand operation output as valid json object * Generated from ac9f623bcc6d676360abc57b52b6ee8b0341ea18 (#2914) Modeling ASG association with VMSS (Service support this hence updating swagger) * [AutoPR compute/resource-manager] Update VMSS planned maintenance description to refer to best practices doc (#2911) * Generated from 93bfe8fd52fa3907af3496b4d37c6a50655cf8ea Update VMSS planned maintenance description to refer to best practices doc * Generated from 93bfe8fd52fa3907af3496b4d37c6a50655cf8ea Update VMSS planned maintenance description to refer to best practices doc * Generated from cb39de62c1bac51455eaf7ad3fbe8ac9ec84df58 (#2918) Add missing ScaleSet properties The change adds the following missing properties 1) "zones" property to VirtualMachineScaleSetVM 2) DiskSizeInGB to VirtualMachineScaleSetOSDisk 3) DiskSizeInGB to VirtualMachineScaleSetUpdateOSDisk * Generated from b59db77683f3a9c65d0edec17b5f05e458a68897 (#2942) Revert AccessUri description to make it correspond to server response * [AutoPR compute/resource-manager] RunCommands 2018-06-01 (#2935) * Generated from 8d08b9c279f07fa5a919205934fd785e329dad64 RunCommands 2018-06-01 * Generated from 9c64257f21823a1d72ec25cd640375f0100638e2 Take examples from 2018-04-01 * Generated from 8f17cd0bc03fad3ed3a5259ec37e9add84ff73a7 (#2965) Fixing instance view object definition in VMSSVMProperties * Fix multi api client * Update Autorest min version for Compute * Fixing tests for latest Compute * Make it stable * ChangeLog
1 parent cf645da commit e8f09d0

File tree

830 files changed

+55123
-4366
lines changed

Some content is hidden

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

830 files changed

+55123
-4366
lines changed

azure-mgmt-compute/HISTORY.rst

+30-2
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,34 @@
33
Release History
44
===============
55

6+
4.0.0 (2018-07-20)
7+
++++++++++++++++++
8+
9+
**Features**
10+
11+
- Model VirtualMachineScaleSetIdentity has a new parameter user_assigned_identities
12+
- Model VirtualMachineScaleSetIPConfiguration has a new parameter application_security_groups
13+
- Model VirtualMachineScaleSetUpdateIPConfiguration has a new parameter application_security_groups
14+
- Model VirtualMachineIdentity has a new parameter user_assigned_identities
15+
- Model LinuxConfiguration has a new parameter provision_vm_agent
16+
- Model OSProfile has a new parameter allow_extension_operations
17+
- Added operation group GalleryImagesOperations
18+
- Added operation group GalleryImageVersionsOperations
19+
- Added operation group GalleriesOperations
20+
- Model UpgradeOperationHistoricalStatusInfoProperties has a new parameter rollback_info
21+
- Model UpgradePolicy has a new parameter auto_os_upgrade_policy
22+
- Added operation AvailabilitySetsOperations.list_by_subscription
23+
24+
**Breaking changes**
25+
26+
- Model VirtualMachineScaleSetIdentity no longer has parameter identity_ids
27+
- Model VirtualMachineScaleSetOSDisk no longer has parameter disk_size_gb
28+
- Model VirtualMachineScaleSetVM no longer has parameter zones
29+
- Model VirtualMachineScaleSetUpdateOSDisk no longer has parameter disk_size_gb
30+
- Model VirtualMachineIdentity no longer has parameter identity_ids
31+
32+
New default API Version is now 2018-06-01
33+
634
4.0.0rc2 (2018-04-17)
735
+++++++++++++++++++++
836

@@ -40,7 +68,7 @@ This version uses a next-generation code generator that *might* introduce breaki
4068

4169
- Return type changes from `msrestazure.azure_operation.AzureOperationPoller` to `msrest.polling.LROPoller`. External API is the same.
4270
- Return type is now **always** a `msrest.polling.LROPoller`, regardless of the optional parameters used.
43-
- The behavior has changed when using `raw=True`. Instead of returning the initial call result as `ClientRawResponse`,
71+
- The behavior has changed when using `raw=True`. Instead of returning the initial call result as `ClientRawResponse`,
4472
without polling, now this returns an LROPoller. After polling, the final resource will be returned as a `ClientRawResponse`.
4573
- New `polling` parameter. The default behavior is `Polling=True` which will poll using ARM algorithm. When `Polling=False`,
4674
the response of the initial call will be returned without polling.
@@ -216,7 +244,7 @@ to use the new Managed Disk feature instead of Storage.
216244

217245
New APIVersion for "container" 2016-09-30.
218246

219-
* several parameters (e.g. "username") now dynamically check before REST calls validity
247+
* several parameters (e.g. "username") now dynamically check before REST calls validity
220248
against a regexp. Exception will be TypeError and not CloudError anymore.
221249

222250
0.31.0 (2016-11-01)

azure-mgmt-compute/azure/mgmt/compute/compute_management_client.py

+140-10
Large diffs are not rendered by default.

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/compute_management_client.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from msrest.service_client import ServiceClient
12+
from msrest.service_client import SDKClient
1313
from msrest import Serializer, Deserializer
1414
from msrestazure import AzureConfiguration
1515
from .version import VERSION
@@ -59,7 +59,7 @@ def __init__(
5959
self.subscription_id = subscription_id
6060

6161

62-
class ComputeManagementClient(object):
62+
class ComputeManagementClient(SDKClient):
6363
"""Compute Client
6464
6565
:ivar config: Configuration for client.
@@ -98,7 +98,7 @@ def __init__(
9898
self, credentials, subscription_id, base_url=None):
9999

100100
self.config = ComputeManagementClientConfiguration(credentials, subscription_id, base_url)
101-
self._client = ServiceClient(self.config.credentials, self.config)
101+
super(ComputeManagementClient, self).__init__(self.config.credentials, self.config)
102102

103103
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
104104
self.api_version = '2015-06-15'

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/__init__.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@
7878
from .virtual_machine_scale_set_instance_view_py3 import VirtualMachineScaleSetInstanceView
7979
from .virtual_machine_scale_set_sku_capacity_py3 import VirtualMachineScaleSetSkuCapacity
8080
from .virtual_machine_scale_set_sku_py3 import VirtualMachineScaleSetSku
81-
from .virtual_machine_scale_set_vm_py3 import VirtualMachineScaleSetVM
8281
from .virtual_machine_scale_set_vm_instance_view_py3 import VirtualMachineScaleSetVMInstanceView
82+
from .virtual_machine_scale_set_vm_py3 import VirtualMachineScaleSetVM
8383
from .api_error_base_py3 import ApiErrorBase
8484
from .inner_error_py3 import InnerError
8585
from .api_error_py3 import ApiError
@@ -156,8 +156,8 @@
156156
from .virtual_machine_scale_set_instance_view import VirtualMachineScaleSetInstanceView
157157
from .virtual_machine_scale_set_sku_capacity import VirtualMachineScaleSetSkuCapacity
158158
from .virtual_machine_scale_set_sku import VirtualMachineScaleSetSku
159-
from .virtual_machine_scale_set_vm import VirtualMachineScaleSetVM
160159
from .virtual_machine_scale_set_vm_instance_view import VirtualMachineScaleSetVMInstanceView
160+
from .virtual_machine_scale_set_vm import VirtualMachineScaleSetVM
161161
from .api_error_base import ApiErrorBase
162162
from .inner_error import InnerError
163163
from .api_error import ApiError
@@ -256,8 +256,8 @@
256256
'VirtualMachineScaleSetInstanceView',
257257
'VirtualMachineScaleSetSkuCapacity',
258258
'VirtualMachineScaleSetSku',
259-
'VirtualMachineScaleSetVM',
260259
'VirtualMachineScaleSetVMInstanceView',
260+
'VirtualMachineScaleSetVM',
261261
'ApiErrorBase',
262262
'InnerError',
263263
'ApiError',

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/availability_set_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class AvailabilitySet(Resource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/network_interface_reference_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class NetworkInterfaceReference(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_capture_result_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class VirtualMachineCaptureResult(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_extension_image_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class VirtualMachineExtensionImage(Resource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_extension_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class VirtualMachineExtension(Resource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_extension_update_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .update_resource import UpdateResource
12+
from .update_resource_py3 import UpdateResource
1313

1414

1515
class VirtualMachineExtensionUpdate(UpdateResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_image_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .virtual_machine_image_resource import VirtualMachineImageResource
12+
from .virtual_machine_image_resource_py3 import VirtualMachineImageResource
1313

1414

1515
class VirtualMachineImage(VirtualMachineImageResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_image_resource_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class VirtualMachineImageResource(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class VirtualMachine(Resource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_extension_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class VirtualMachineScaleSetExtension(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_ip_configuration_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class VirtualMachineScaleSetIPConfiguration(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_network_configuration_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .sub_resource import SubResource
12+
from .sub_resource_py3 import SubResource
1313

1414

1515
class VirtualMachineScaleSetNetworkConfiguration(SubResource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_py3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class VirtualMachineScaleSet(Resource):

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_vm.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class VirtualMachineScaleSetVM(Resource):
3939
:vartype latest_model_applied: bool
4040
:ivar instance_view: The virtual machine instance view.
4141
:vartype instance_view:
42-
~azure.mgmt.compute.v2015_06_15.models.VirtualMachineInstanceView
42+
~azure.mgmt.compute.v2015_06_15.models.VirtualMachineScaleSetVMInstanceView
4343
:param hardware_profile: Specifies the hardware settings for the virtual
4444
machine.
4545
:type hardware_profile:
@@ -118,7 +118,7 @@ class VirtualMachineScaleSetVM(Resource):
118118
'instance_id': {'key': 'instanceId', 'type': 'str'},
119119
'sku': {'key': 'sku', 'type': 'Sku'},
120120
'latest_model_applied': {'key': 'properties.latestModelApplied', 'type': 'bool'},
121-
'instance_view': {'key': 'properties.instanceView', 'type': 'VirtualMachineInstanceView'},
121+
'instance_view': {'key': 'properties.instanceView', 'type': 'VirtualMachineScaleSetVMInstanceView'},
122122
'hardware_profile': {'key': 'properties.hardwareProfile', 'type': 'HardwareProfile'},
123123
'storage_profile': {'key': 'properties.storageProfile', 'type': 'StorageProfile'},
124124
'os_profile': {'key': 'properties.osProfile', 'type': 'OSProfile'},

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/models/virtual_machine_scale_set_vm_py3.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# regenerated.
1010
# --------------------------------------------------------------------------
1111

12-
from .resource import Resource
12+
from .resource_py3 import Resource
1313

1414

1515
class VirtualMachineScaleSetVM(Resource):
@@ -39,7 +39,7 @@ class VirtualMachineScaleSetVM(Resource):
3939
:vartype latest_model_applied: bool
4040
:ivar instance_view: The virtual machine instance view.
4141
:vartype instance_view:
42-
~azure.mgmt.compute.v2015_06_15.models.VirtualMachineInstanceView
42+
~azure.mgmt.compute.v2015_06_15.models.VirtualMachineScaleSetVMInstanceView
4343
:param hardware_profile: Specifies the hardware settings for the virtual
4444
machine.
4545
:type hardware_profile:
@@ -118,7 +118,7 @@ class VirtualMachineScaleSetVM(Resource):
118118
'instance_id': {'key': 'instanceId', 'type': 'str'},
119119
'sku': {'key': 'sku', 'type': 'Sku'},
120120
'latest_model_applied': {'key': 'properties.latestModelApplied', 'type': 'bool'},
121-
'instance_view': {'key': 'properties.instanceView', 'type': 'VirtualMachineInstanceView'},
121+
'instance_view': {'key': 'properties.instanceView', 'type': 'VirtualMachineScaleSetVMInstanceView'},
122122
'hardware_profile': {'key': 'properties.hardwareProfile', 'type': 'HardwareProfile'},
123123
'storage_profile': {'key': 'properties.storageProfile', 'type': 'StorageProfile'},
124124
'os_profile': {'key': 'properties.osProfile', 'type': 'OSProfile'},

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/operations/availability_sets_operations.py

+15-17
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ def create_or_update(
7474

7575
# Construct headers
7676
header_parameters = {}
77+
header_parameters['Accept'] = 'application/json'
7778
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
7879
if self.config.generate_client_request_id:
7980
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
@@ -86,9 +87,8 @@ def create_or_update(
8687
body_content = self._serialize.body(parameters, 'AvailabilitySet')
8788

8889
# Construct and send request
89-
request = self._client.put(url, query_parameters)
90-
response = self._client.send(
91-
request, header_parameters, body_content, stream=False, **operation_config)
90+
request = self._client.put(url, query_parameters, header_parameters, body_content)
91+
response = self._client.send(request, stream=False, **operation_config)
9292

9393
if response.status_code not in [200]:
9494
exp = CloudError(response)
@@ -140,7 +140,7 @@ def delete(
140140

141141
# Construct headers
142142
header_parameters = {}
143-
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
143+
header_parameters['Accept'] = 'application/json'
144144
if self.config.generate_client_request_id:
145145
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
146146
if custom_headers:
@@ -149,8 +149,8 @@ def delete(
149149
header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str')
150150

151151
# Construct and send request
152-
request = self._client.delete(url, query_parameters)
153-
response = self._client.send(request, header_parameters, stream=False, **operation_config)
152+
request = self._client.delete(url, query_parameters, header_parameters)
153+
response = self._client.send(request, stream=False, **operation_config)
154154

155155
if response.status_code not in [200, 204]:
156156
exp = CloudError(response)
@@ -202,7 +202,7 @@ def get(
202202

203203
# Construct headers
204204
header_parameters = {}
205-
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
205+
header_parameters['Accept'] = 'application/json'
206206
if self.config.generate_client_request_id:
207207
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
208208
if custom_headers:
@@ -211,8 +211,8 @@ def get(
211211
header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str')
212212

213213
# Construct and send request
214-
request = self._client.get(url, query_parameters)
215-
response = self._client.send(request, header_parameters, stream=False, **operation_config)
214+
request = self._client.get(url, query_parameters, header_parameters)
215+
response = self._client.send(request, stream=False, **operation_config)
216216

217217
if response.status_code not in [200]:
218218
exp = CloudError(response)
@@ -268,7 +268,7 @@ def internal_paging(next_link=None, raw=False):
268268

269269
# Construct headers
270270
header_parameters = {}
271-
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
271+
header_parameters['Accept'] = 'application/json'
272272
if self.config.generate_client_request_id:
273273
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
274274
if custom_headers:
@@ -277,9 +277,8 @@ def internal_paging(next_link=None, raw=False):
277277
header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str')
278278

279279
# Construct and send request
280-
request = self._client.get(url, query_parameters)
281-
response = self._client.send(
282-
request, header_parameters, stream=False, **operation_config)
280+
request = self._client.get(url, query_parameters, header_parameters)
281+
response = self._client.send(request, stream=False, **operation_config)
283282

284283
if response.status_code not in [200]:
285284
exp = CloudError(response)
@@ -340,7 +339,7 @@ def internal_paging(next_link=None, raw=False):
340339

341340
# Construct headers
342341
header_parameters = {}
343-
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
342+
header_parameters['Accept'] = 'application/json'
344343
if self.config.generate_client_request_id:
345344
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
346345
if custom_headers:
@@ -349,9 +348,8 @@ def internal_paging(next_link=None, raw=False):
349348
header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str')
350349

351350
# Construct and send request
352-
request = self._client.get(url, query_parameters)
353-
response = self._client.send(
354-
request, header_parameters, stream=False, **operation_config)
351+
request = self._client.get(url, query_parameters, header_parameters)
352+
response = self._client.send(request, stream=False, **operation_config)
355353

356354
if response.status_code not in [200]:
357355
exp = CloudError(response)

azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/operations/usage_operations.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def internal_paging(next_link=None, raw=False):
7676

7777
# Construct headers
7878
header_parameters = {}
79-
header_parameters['Content-Type'] = 'application/json; charset=utf-8'
79+
header_parameters['Accept'] = 'application/json'
8080
if self.config.generate_client_request_id:
8181
header_parameters['x-ms-client-request-id'] = str(uuid.uuid1())
8282
if custom_headers:
@@ -85,9 +85,8 @@ def internal_paging(next_link=None, raw=False):
8585
header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str')
8686

8787
# Construct and send request
88-
request = self._client.get(url, query_parameters)
89-
response = self._client.send(
90-
request, header_parameters, stream=False, **operation_config)
88+
request = self._client.get(url, query_parameters, header_parameters)
89+
response = self._client.send(request, stream=False, **operation_config)
9190

9291
if response.status_code not in [200]:
9392
exp = CloudError(response)

0 commit comments

Comments
 (0)