azure_mgmt_server_management 0.6.0 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 144f136878b3606af8fa613ef4bc1abd35ebadd6
4
- data.tar.gz: 09e789f01155fda4b535918afbe16611386c8b25
3
+ metadata.gz: 97f74538f1f80f0e3f2e85f9dc9bcc4681b25bba
4
+ data.tar.gz: bde9cd6323cdb152bd96eb4acf773421e8b6f991
5
5
  SHA512:
6
- metadata.gz: 3d245aee4e6fd508caa114db03d5b5129b5a09d4e658c542d1289154860fab2fb8627a07dfc7ea466233b801d93bfcd56c81373727735379a993774618792426
7
- data.tar.gz: 999d53807383cb62ae207528692c27df864774993367f6114f60f56d8ba8711d0edf9ad34b0deb84111389936a5fd39b42ff8d0e9a7df57553b9233e55539494
6
+ metadata.gz: b4862fe6775bb9503ac3d497df108521d827398aaa16b3423864375911036131dff3c45c27daa3b9387c13ec0bb155c57c39534c365025a16c7391bffcec1e2b
7
+ data.tar.gz: 4d125f85f6591e22973a63cc37b022eb5ee20a9d3e6e054fd9b5eb916ffeee02e8958580cbc389b06f55862f4d9a5ee97407bfb55c5aaf5dc5966884071025b2
@@ -165,31 +165,28 @@ module Azure::ARM::ServerManagement
165
165
  request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
166
166
 
167
167
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}'
168
+
169
+ request_url = @base_url || @client.base_url
170
+
168
171
  options = {
169
172
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
170
173
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
171
174
  query_params: {'api-version' => @client.api_version},
172
175
  body: request_content,
173
- headers: request_headers.merge(custom_headers || {})
176
+ headers: request_headers.merge(custom_headers || {}),
177
+ base_url: request_url
174
178
  }
179
+ promise = @client.make_request_async(:put, path_template, options)
175
180
 
176
- request_url = @base_url || @client.base_url
177
-
178
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :put, options)
179
- promise = request.run_promise do |req|
180
- @client.credentials.sign_request(req) unless @client.credentials.nil?
181
- end
182
-
183
- promise = promise.then do |http_response|
181
+ promise = promise.then do |result|
182
+ http_response = result.response
184
183
  status_code = http_response.status
185
184
  response_content = http_response.body
186
185
  unless status_code == 200 || status_code == 201
187
186
  error_model = JSON.load(response_content)
188
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
187
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
189
188
  end
190
189
 
191
- # Create Result
192
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
193
190
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
194
191
  # Deserialize Response
195
192
  if status_code == 200
@@ -361,31 +358,28 @@ module Azure::ARM::ServerManagement
361
358
  request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
362
359
 
363
360
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}'
361
+
362
+ request_url = @base_url || @client.base_url
363
+
364
364
  options = {
365
365
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
366
366
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
367
367
  query_params: {'api-version' => @client.api_version},
368
368
  body: request_content,
369
- headers: request_headers.merge(custom_headers || {})
369
+ headers: request_headers.merge(custom_headers || {}),
370
+ base_url: request_url
370
371
  }
372
+ promise = @client.make_request_async(:patch, path_template, options)
371
373
 
372
- request_url = @base_url || @client.base_url
373
-
374
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :patch, options)
375
- promise = request.run_promise do |req|
376
- @client.credentials.sign_request(req) unless @client.credentials.nil?
377
- end
378
-
379
- promise = promise.then do |http_response|
374
+ promise = promise.then do |result|
375
+ http_response = result.response
380
376
  status_code = http_response.status
381
377
  response_content = http_response.body
382
378
  unless status_code == 200 || status_code == 202
383
379
  error_model = JSON.load(response_content)
384
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
380
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
385
381
  end
386
382
 
387
- # Create Result
388
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
389
383
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
390
384
  # Deserialize Response
391
385
  if status_code == 200
@@ -458,30 +452,27 @@ module Azure::ARM::ServerManagement
458
452
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
459
453
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
460
454
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}'
455
+
456
+ request_url = @base_url || @client.base_url
457
+
461
458
  options = {
462
459
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
463
460
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
464
461
  query_params: {'api-version' => @client.api_version},
465
- headers: request_headers.merge(custom_headers || {})
462
+ headers: request_headers.merge(custom_headers || {}),
463
+ base_url: request_url
466
464
  }
465
+ promise = @client.make_request_async(:delete, path_template, options)
467
466
 
468
- request_url = @base_url || @client.base_url
469
-
470
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :delete, options)
471
- promise = request.run_promise do |req|
472
- @client.credentials.sign_request(req) unless @client.credentials.nil?
473
- end
474
-
475
- promise = promise.then do |http_response|
467
+ promise = promise.then do |result|
468
+ http_response = result.response
476
469
  status_code = http_response.status
477
470
  response_content = http_response.body
478
471
  unless status_code == 200 || status_code == 204
479
472
  error_model = JSON.load(response_content)
480
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
473
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
481
474
  end
482
475
 
483
- # Create Result
484
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
485
476
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
486
477
 
487
478
  result
@@ -554,30 +545,27 @@ module Azure::ARM::ServerManagement
554
545
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
555
546
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
556
547
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}'
548
+
549
+ request_url = @base_url || @client.base_url
550
+
557
551
  options = {
558
552
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
559
553
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
560
554
  query_params: {'api-version' => @client.api_version,'$expand' => expand},
561
- headers: request_headers.merge(custom_headers || {})
555
+ headers: request_headers.merge(custom_headers || {}),
556
+ base_url: request_url
562
557
  }
558
+ promise = @client.make_request_async(:get, path_template, options)
563
559
 
564
- request_url = @base_url || @client.base_url
565
-
566
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :get, options)
567
- promise = request.run_promise do |req|
568
- @client.credentials.sign_request(req) unless @client.credentials.nil?
569
- end
570
-
571
- promise = promise.then do |http_response|
560
+ promise = promise.then do |result|
561
+ http_response = result.response
572
562
  status_code = http_response.status
573
563
  response_content = http_response.body
574
564
  unless status_code == 200
575
565
  error_model = JSON.load(response_content)
576
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
566
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
577
567
  end
578
568
 
579
- # Create Result
580
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
581
569
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
582
570
  # Deserialize Response
583
571
  if status_code == 200
@@ -609,8 +597,8 @@ module Azure::ARM::ServerManagement
609
597
  response = list_async(custom_headers).value!
610
598
  unless response.nil?
611
599
  page = response.body
612
- page.next_method = Proc.new do |next_link|
613
- list_next_async(next_link, custom_headers)
600
+ page.next_method = Proc.new do |next_page_link|
601
+ list_next_async(next_page_link, custom_headers)
614
602
  end
615
603
  page
616
604
  end
@@ -660,30 +648,27 @@ module Azure::ARM::ServerManagement
660
648
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
661
649
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
662
650
  path_template = '/subscriptions/{subscriptionId}/providers/Microsoft.ServerManagement/gateways'
651
+
652
+ request_url = @base_url || @client.base_url
653
+
663
654
  options = {
664
655
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
665
656
  path_params: {'subscriptionId' => @client.subscription_id},
666
657
  query_params: {'api-version' => @client.api_version},
667
- headers: request_headers.merge(custom_headers || {})
658
+ headers: request_headers.merge(custom_headers || {}),
659
+ base_url: request_url
668
660
  }
661
+ promise = @client.make_request_async(:get, path_template, options)
669
662
 
670
- request_url = @base_url || @client.base_url
671
-
672
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :get, options)
673
- promise = request.run_promise do |req|
674
- @client.credentials.sign_request(req) unless @client.credentials.nil?
675
- end
676
-
677
- promise = promise.then do |http_response|
663
+ promise = promise.then do |result|
664
+ http_response = result.response
678
665
  status_code = http_response.status
679
666
  response_content = http_response.body
680
667
  unless status_code == 200
681
668
  error_model = JSON.load(response_content)
682
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
669
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
683
670
  end
684
671
 
685
- # Create Result
686
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
687
672
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
688
673
  # Deserialize Response
689
674
  if status_code == 200
@@ -717,8 +702,8 @@ module Azure::ARM::ServerManagement
717
702
  response = list_for_resource_group_async(resource_group_name, custom_headers).value!
718
703
  unless response.nil?
719
704
  page = response.body
720
- page.next_method = Proc.new do |next_link|
721
- list_for_resource_group_next_async(next_link, custom_headers)
705
+ page.next_method = Proc.new do |next_page_link|
706
+ list_for_resource_group_next_async(next_page_link, custom_headers)
722
707
  end
723
708
  page
724
709
  end
@@ -775,30 +760,27 @@ module Azure::ARM::ServerManagement
775
760
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
776
761
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
777
762
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways'
763
+
764
+ request_url = @base_url || @client.base_url
765
+
778
766
  options = {
779
767
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
780
768
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name},
781
769
  query_params: {'api-version' => @client.api_version},
782
- headers: request_headers.merge(custom_headers || {})
770
+ headers: request_headers.merge(custom_headers || {}),
771
+ base_url: request_url
783
772
  }
773
+ promise = @client.make_request_async(:get, path_template, options)
784
774
 
785
- request_url = @base_url || @client.base_url
786
-
787
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :get, options)
788
- promise = request.run_promise do |req|
789
- @client.credentials.sign_request(req) unless @client.credentials.nil?
790
- end
791
-
792
- promise = promise.then do |http_response|
775
+ promise = promise.then do |result|
776
+ http_response = result.response
793
777
  status_code = http_response.status
794
778
  response_content = http_response.body
795
779
  unless status_code == 200
796
780
  error_model = JSON.load(response_content)
797
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
781
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
798
782
  end
799
783
 
800
- # Create Result
801
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
802
784
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
803
785
  # Deserialize Response
804
786
  if status_code == 200
@@ -911,30 +893,27 @@ module Azure::ARM::ServerManagement
911
893
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
912
894
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
913
895
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/upgradetolatest'
896
+
897
+ request_url = @base_url || @client.base_url
898
+
914
899
  options = {
915
900
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
916
901
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
917
902
  query_params: {'api-version' => @client.api_version},
918
- headers: request_headers.merge(custom_headers || {})
903
+ headers: request_headers.merge(custom_headers || {}),
904
+ base_url: request_url
919
905
  }
906
+ promise = @client.make_request_async(:post, path_template, options)
920
907
 
921
- request_url = @base_url || @client.base_url
922
-
923
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :post, options)
924
- promise = request.run_promise do |req|
925
- @client.credentials.sign_request(req) unless @client.credentials.nil?
926
- end
927
-
928
- promise = promise.then do |http_response|
908
+ promise = promise.then do |result|
909
+ http_response = result.response
929
910
  status_code = http_response.status
930
911
  response_content = http_response.body
931
912
  unless status_code == 200 || status_code == 202
932
913
  error_model = JSON.load(response_content)
933
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
914
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
934
915
  end
935
916
 
936
- # Create Result
937
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
938
917
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
939
918
 
940
919
  result
@@ -1037,30 +1016,27 @@ module Azure::ARM::ServerManagement
1037
1016
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1038
1017
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1039
1018
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/regenerateprofile'
1019
+
1020
+ request_url = @base_url || @client.base_url
1021
+
1040
1022
  options = {
1041
1023
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1042
1024
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
1043
1025
  query_params: {'api-version' => @client.api_version},
1044
- headers: request_headers.merge(custom_headers || {})
1026
+ headers: request_headers.merge(custom_headers || {}),
1027
+ base_url: request_url
1045
1028
  }
1029
+ promise = @client.make_request_async(:post, path_template, options)
1046
1030
 
1047
- request_url = @base_url || @client.base_url
1048
-
1049
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :post, options)
1050
- promise = request.run_promise do |req|
1051
- @client.credentials.sign_request(req) unless @client.credentials.nil?
1052
- end
1053
-
1054
- promise = promise.then do |http_response|
1031
+ promise = promise.then do |result|
1032
+ http_response = result.response
1055
1033
  status_code = http_response.status
1056
1034
  response_content = http_response.body
1057
1035
  unless status_code == 200 || status_code == 202
1058
1036
  error_model = JSON.load(response_content)
1059
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
1037
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
1060
1038
  end
1061
1039
 
1062
- # Create Result
1063
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
1064
1040
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1065
1041
 
1066
1042
  result
@@ -1168,30 +1144,27 @@ module Azure::ARM::ServerManagement
1168
1144
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1169
1145
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1170
1146
  path_template = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServerManagement/gateways/{gatewayName}/profile'
1147
+
1148
+ request_url = @base_url || @client.base_url
1149
+
1171
1150
  options = {
1172
1151
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1173
1152
  path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'gatewayName' => gateway_name},
1174
1153
  query_params: {'api-version' => @client.api_version},
1175
- headers: request_headers.merge(custom_headers || {})
1154
+ headers: request_headers.merge(custom_headers || {}),
1155
+ base_url: request_url
1176
1156
  }
1157
+ promise = @client.make_request_async(:post, path_template, options)
1177
1158
 
1178
- request_url = @base_url || @client.base_url
1179
-
1180
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :post, options)
1181
- promise = request.run_promise do |req|
1182
- @client.credentials.sign_request(req) unless @client.credentials.nil?
1183
- end
1184
-
1185
- promise = promise.then do |http_response|
1159
+ promise = promise.then do |result|
1160
+ http_response = result.response
1186
1161
  status_code = http_response.status
1187
1162
  response_content = http_response.body
1188
1163
  unless status_code == 200 || status_code == 202
1189
1164
  error_model = JSON.load(response_content)
1190
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
1165
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
1191
1166
  end
1192
1167
 
1193
- # Create Result
1194
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
1195
1168
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1196
1169
  # Deserialize Response
1197
1170
  if status_code == 200
@@ -1259,29 +1232,26 @@ module Azure::ARM::ServerManagement
1259
1232
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1260
1233
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1261
1234
  path_template = '{nextLink}'
1235
+
1236
+ request_url = @base_url || @client.base_url
1237
+
1262
1238
  options = {
1263
1239
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1264
1240
  skip_encoding_path_params: {'nextLink' => next_page_link},
1265
- headers: request_headers.merge(custom_headers || {})
1241
+ headers: request_headers.merge(custom_headers || {}),
1242
+ base_url: request_url
1266
1243
  }
1244
+ promise = @client.make_request_async(:get, path_template, options)
1267
1245
 
1268
- request_url = @base_url || @client.base_url
1269
-
1270
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :get, options)
1271
- promise = request.run_promise do |req|
1272
- @client.credentials.sign_request(req) unless @client.credentials.nil?
1273
- end
1274
-
1275
- promise = promise.then do |http_response|
1246
+ promise = promise.then do |result|
1247
+ http_response = result.response
1276
1248
  status_code = http_response.status
1277
1249
  response_content = http_response.body
1278
1250
  unless status_code == 200
1279
1251
  error_model = JSON.load(response_content)
1280
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
1252
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
1281
1253
  end
1282
1254
 
1283
- # Create Result
1284
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
1285
1255
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1286
1256
  # Deserialize Response
1287
1257
  if status_code == 200
@@ -1349,29 +1319,26 @@ module Azure::ARM::ServerManagement
1349
1319
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1350
1320
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1351
1321
  path_template = '{nextLink}'
1322
+
1323
+ request_url = @base_url || @client.base_url
1324
+
1352
1325
  options = {
1353
1326
  middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1354
1327
  skip_encoding_path_params: {'nextLink' => next_page_link},
1355
- headers: request_headers.merge(custom_headers || {})
1328
+ headers: request_headers.merge(custom_headers || {}),
1329
+ base_url: request_url
1356
1330
  }
1331
+ promise = @client.make_request_async(:get, path_template, options)
1357
1332
 
1358
- request_url = @base_url || @client.base_url
1359
-
1360
- request = MsRest::HttpOperationRequest.new(request_url, path_template, :get, options)
1361
- promise = request.run_promise do |req|
1362
- @client.credentials.sign_request(req) unless @client.credentials.nil?
1363
- end
1364
-
1365
- promise = promise.then do |http_response|
1333
+ promise = promise.then do |result|
1334
+ http_response = result.response
1366
1335
  status_code = http_response.status
1367
1336
  response_content = http_response.body
1368
1337
  unless status_code == 200
1369
1338
  error_model = JSON.load(response_content)
1370
- fail MsRest::HttpOperationError.new(request, http_response, error_model)
1339
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
1371
1340
  end
1372
1341
 
1373
- # Create Result
1374
- result = MsRestAzure::AzureOperationResponse.new(request, http_response)
1375
1342
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1376
1343
  # Deserialize Response
1377
1344
  if status_code == 200