azure_mgmt_event_grid 0.14.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (38) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +21 -0
  3. data/lib/azure_mgmt_event_grid.rb +6 -0
  4. data/lib/generated/azure_mgmt_event_grid.rb +57 -0
  5. data/lib/generated/azure_mgmt_event_grid/event_grid_management_client.rb +143 -0
  6. data/lib/generated/azure_mgmt_event_grid/event_subscriptions.rb +1803 -0
  7. data/lib/generated/azure_mgmt_event_grid/models/event_hub_event_subscription_destination.rb +59 -0
  8. data/lib/generated/azure_mgmt_event_grid/models/event_subscription.rb +126 -0
  9. data/lib/generated/azure_mgmt_event_grid/models/event_subscription_destination.rb +46 -0
  10. data/lib/generated/azure_mgmt_event_grid/models/event_subscription_filter.rb +92 -0
  11. data/lib/generated/azure_mgmt_event_grid/models/event_subscription_full_url.rb +45 -0
  12. data/lib/generated/azure_mgmt_event_grid/models/event_subscription_provisioning_state.rb +20 -0
  13. data/lib/generated/azure_mgmt_event_grid/models/event_subscription_update_parameters.rb +78 -0
  14. data/lib/generated/azure_mgmt_event_grid/models/event_subscriptions_list_result.rb +52 -0
  15. data/lib/generated/azure_mgmt_event_grid/models/event_type.rb +88 -0
  16. data/lib/generated/azure_mgmt_event_grid/models/event_types_list_result.rb +52 -0
  17. data/lib/generated/azure_mgmt_event_grid/models/operation.rb +76 -0
  18. data/lib/generated/azure_mgmt_event_grid/models/operation_info.rb +74 -0
  19. data/lib/generated/azure_mgmt_event_grid/models/operation_origin.rb +17 -0
  20. data/lib/generated/azure_mgmt_event_grid/models/operations_list_result.rb +52 -0
  21. data/lib/generated/azure_mgmt_event_grid/models/resource.rb +67 -0
  22. data/lib/generated/azure_mgmt_event_grid/models/resource_region_type.rb +16 -0
  23. data/lib/generated/azure_mgmt_event_grid/models/topic.rb +103 -0
  24. data/lib/generated/azure_mgmt_event_grid/models/topic_provisioning_state.rb +20 -0
  25. data/lib/generated/azure_mgmt_event_grid/models/topic_regenerate_key_request.rb +44 -0
  26. data/lib/generated/azure_mgmt_event_grid/models/topic_shared_access_keys.rb +54 -0
  27. data/lib/generated/azure_mgmt_event_grid/models/topic_type_info.rb +128 -0
  28. data/lib/generated/azure_mgmt_event_grid/models/topic_type_provisioning_state.rb +20 -0
  29. data/lib/generated/azure_mgmt_event_grid/models/topic_types_list_result.rb +52 -0
  30. data/lib/generated/azure_mgmt_event_grid/models/topics_list_result.rb +52 -0
  31. data/lib/generated/azure_mgmt_event_grid/models/tracked_resource.rb +85 -0
  32. data/lib/generated/azure_mgmt_event_grid/models/web_hook_event_subscription_destination.rb +71 -0
  33. data/lib/generated/azure_mgmt_event_grid/module_definition.rb +8 -0
  34. data/lib/generated/azure_mgmt_event_grid/operations.rb +115 -0
  35. data/lib/generated/azure_mgmt_event_grid/topic_types.rb +296 -0
  36. data/lib/generated/azure_mgmt_event_grid/topics.rb +926 -0
  37. data/lib/generated/azure_mgmt_event_grid/version.rb +8 -0
  38. metadata +149 -0
@@ -0,0 +1,52 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ARM::EventGrid
7
+ module Models
8
+ #
9
+ # Result of the List Topics operation
10
+ #
11
+ class TopicsListResult
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [Array<Topic>] A collection of Topics
16
+ attr_accessor :value
17
+
18
+
19
+ #
20
+ # Mapper for TopicsListResult class as Ruby Hash.
21
+ # This will be used for serialization/deserialization.
22
+ #
23
+ def self.mapper()
24
+ {
25
+ required: false,
26
+ serialized_name: 'TopicsListResult',
27
+ type: {
28
+ name: 'Composite',
29
+ class_name: 'TopicsListResult',
30
+ model_properties: {
31
+ value: {
32
+ required: false,
33
+ serialized_name: 'value',
34
+ type: {
35
+ name: 'Sequence',
36
+ element: {
37
+ required: false,
38
+ serialized_name: 'TopicElementType',
39
+ type: {
40
+ name: 'Composite',
41
+ class_name: 'Topic'
42
+ }
43
+ }
44
+ }
45
+ }
46
+ }
47
+ }
48
+ }
49
+ end
50
+ end
51
+ end
52
+ end
@@ -0,0 +1,85 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ARM::EventGrid
7
+ module Models
8
+ #
9
+ # Definition of a Tracked Resource
10
+ #
11
+ class TrackedResource < Resource
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [String] Location of the resource
16
+ attr_accessor :location
17
+
18
+ # @return [Hash{String => String}] Tags of the resource
19
+ attr_accessor :tags
20
+
21
+
22
+ #
23
+ # Mapper for TrackedResource class as Ruby Hash.
24
+ # This will be used for serialization/deserialization.
25
+ #
26
+ def self.mapper()
27
+ {
28
+ required: false,
29
+ serialized_name: 'TrackedResource',
30
+ type: {
31
+ name: 'Composite',
32
+ class_name: 'TrackedResource',
33
+ model_properties: {
34
+ id: {
35
+ required: false,
36
+ read_only: true,
37
+ serialized_name: 'id',
38
+ type: {
39
+ name: 'String'
40
+ }
41
+ },
42
+ name: {
43
+ required: false,
44
+ read_only: true,
45
+ serialized_name: 'name',
46
+ type: {
47
+ name: 'String'
48
+ }
49
+ },
50
+ type: {
51
+ required: false,
52
+ read_only: true,
53
+ serialized_name: 'type',
54
+ type: {
55
+ name: 'String'
56
+ }
57
+ },
58
+ location: {
59
+ required: true,
60
+ serialized_name: 'location',
61
+ type: {
62
+ name: 'String'
63
+ }
64
+ },
65
+ tags: {
66
+ required: false,
67
+ serialized_name: 'tags',
68
+ type: {
69
+ name: 'Dictionary',
70
+ value: {
71
+ required: false,
72
+ serialized_name: 'StringElementType',
73
+ type: {
74
+ name: 'String'
75
+ }
76
+ }
77
+ }
78
+ }
79
+ }
80
+ }
81
+ }
82
+ end
83
+ end
84
+ end
85
+ end
@@ -0,0 +1,71 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ARM::EventGrid
7
+ module Models
8
+ #
9
+ # Information about the webhook destination for an event subscription
10
+ #
11
+ class WebHookEventSubscriptionDestination < EventSubscriptionDestination
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ def initialize
17
+ @endpointType = "WebHook"
18
+ end
19
+
20
+ attr_accessor :endpointType
21
+
22
+ # @return [String] The URL that represents the endpoint of the
23
+ # destination of an event subscription.
24
+ attr_accessor :endpoint_url
25
+
26
+ # @return [String] The base URL that represents the endpoint of the
27
+ # destination of an event subscription.
28
+ attr_accessor :endpoint_base_url
29
+
30
+
31
+ #
32
+ # Mapper for WebHookEventSubscriptionDestination class as Ruby Hash.
33
+ # This will be used for serialization/deserialization.
34
+ #
35
+ def self.mapper()
36
+ {
37
+ required: false,
38
+ serialized_name: 'WebHook',
39
+ type: {
40
+ name: 'Composite',
41
+ class_name: 'WebHookEventSubscriptionDestination',
42
+ model_properties: {
43
+ endpointType: {
44
+ required: true,
45
+ serialized_name: 'endpointType',
46
+ type: {
47
+ name: 'String'
48
+ }
49
+ },
50
+ endpoint_url: {
51
+ required: false,
52
+ serialized_name: 'properties.endpointUrl',
53
+ type: {
54
+ name: 'String'
55
+ }
56
+ },
57
+ endpoint_base_url: {
58
+ required: false,
59
+ read_only: true,
60
+ serialized_name: 'properties.endpointBaseUrl',
61
+ type: {
62
+ name: 'String'
63
+ }
64
+ }
65
+ }
66
+ }
67
+ }
68
+ end
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,8 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure end
7
+ module Azure::ARM end
8
+ module Azure::ARM::EventGrid end
@@ -0,0 +1,115 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ARM::EventGrid
7
+ #
8
+ # Azure EventGrid Management Client
9
+ #
10
+ class Operations
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the Operations class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [EventGridManagementClient] reference to the EventGridManagementClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # List available operations
26
+ #
27
+ # List the available operations supported by the Microsoft.EventGrid resource
28
+ # provider
29
+ #
30
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
31
+ # will be added to the HTTP request.
32
+ #
33
+ # @return [OperationsListResult] operation results.
34
+ #
35
+ def list(custom_headers = nil)
36
+ response = list_async(custom_headers).value!
37
+ response.body unless response.nil?
38
+ end
39
+
40
+ #
41
+ # List available operations
42
+ #
43
+ # List the available operations supported by the Microsoft.EventGrid resource
44
+ # provider
45
+ #
46
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
47
+ # will be added to the HTTP request.
48
+ #
49
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
50
+ #
51
+ def list_with_http_info(custom_headers = nil)
52
+ list_async(custom_headers).value!
53
+ end
54
+
55
+ #
56
+ # List available operations
57
+ #
58
+ # List the available operations supported by the Microsoft.EventGrid resource
59
+ # provider
60
+ #
61
+ # @param [Hash{String => String}] A hash of custom headers that will be added
62
+ # to the HTTP request.
63
+ #
64
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
65
+ #
66
+ def list_async(custom_headers = nil)
67
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
68
+
69
+
70
+ request_headers = {}
71
+
72
+ # Set Headers
73
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
74
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
75
+ path_template = 'providers/Microsoft.EventGrid/operations'
76
+
77
+ request_url = @base_url || @client.base_url
78
+
79
+ options = {
80
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
81
+ query_params: {'api-version' => @client.api_version},
82
+ headers: request_headers.merge(custom_headers || {}),
83
+ base_url: request_url
84
+ }
85
+ promise = @client.make_request_async(:get, path_template, options)
86
+
87
+ promise = promise.then do |result|
88
+ http_response = result.response
89
+ status_code = http_response.status
90
+ response_content = http_response.body
91
+ unless status_code == 200
92
+ error_model = JSON.load(response_content)
93
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
94
+ end
95
+
96
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
97
+ # Deserialize Response
98
+ if status_code == 200
99
+ begin
100
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
101
+ result_mapper = Azure::ARM::EventGrid::Models::OperationsListResult.mapper()
102
+ result.body = @client.deserialize(result_mapper, parsed_response)
103
+ rescue Exception => e
104
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
105
+ end
106
+ end
107
+
108
+ result
109
+ end
110
+
111
+ promise.execute
112
+ end
113
+
114
+ end
115
+ end
@@ -0,0 +1,296 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ARM::EventGrid
7
+ #
8
+ # Azure EventGrid Management Client
9
+ #
10
+ class TopicTypes
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the TopicTypes class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [EventGridManagementClient] reference to the EventGridManagementClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # List topic types
26
+ #
27
+ # List all registered topic types
28
+ #
29
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
30
+ # will be added to the HTTP request.
31
+ #
32
+ # @return [TopicTypesListResult] operation results.
33
+ #
34
+ def list(custom_headers = nil)
35
+ response = list_async(custom_headers).value!
36
+ response.body unless response.nil?
37
+ end
38
+
39
+ #
40
+ # List topic types
41
+ #
42
+ # List all registered topic types
43
+ #
44
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
45
+ # will be added to the HTTP request.
46
+ #
47
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
48
+ #
49
+ def list_with_http_info(custom_headers = nil)
50
+ list_async(custom_headers).value!
51
+ end
52
+
53
+ #
54
+ # List topic types
55
+ #
56
+ # List all registered topic types
57
+ #
58
+ # @param [Hash{String => String}] A hash of custom headers that will be added
59
+ # to the HTTP request.
60
+ #
61
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
62
+ #
63
+ def list_async(custom_headers = nil)
64
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
65
+
66
+
67
+ request_headers = {}
68
+
69
+ # Set Headers
70
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
71
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
72
+ path_template = 'providers/Microsoft.EventGrid/topicTypes'
73
+
74
+ request_url = @base_url || @client.base_url
75
+
76
+ options = {
77
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
78
+ query_params: {'api-version' => @client.api_version},
79
+ headers: request_headers.merge(custom_headers || {}),
80
+ base_url: request_url
81
+ }
82
+ promise = @client.make_request_async(:get, path_template, options)
83
+
84
+ promise = promise.then do |result|
85
+ http_response = result.response
86
+ status_code = http_response.status
87
+ response_content = http_response.body
88
+ unless status_code == 200
89
+ error_model = JSON.load(response_content)
90
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
91
+ end
92
+
93
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
94
+ # Deserialize Response
95
+ if status_code == 200
96
+ begin
97
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
98
+ result_mapper = Azure::ARM::EventGrid::Models::TopicTypesListResult.mapper()
99
+ result.body = @client.deserialize(result_mapper, parsed_response)
100
+ rescue Exception => e
101
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
102
+ end
103
+ end
104
+
105
+ result
106
+ end
107
+
108
+ promise.execute
109
+ end
110
+
111
+ #
112
+ # Get a topic type
113
+ #
114
+ # Get information about a topic type
115
+ #
116
+ # @param topic_type_name [String] Name of the topic type
117
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
118
+ # will be added to the HTTP request.
119
+ #
120
+ # @return [TopicTypeInfo] operation results.
121
+ #
122
+ def get(topic_type_name, custom_headers = nil)
123
+ response = get_async(topic_type_name, custom_headers).value!
124
+ response.body unless response.nil?
125
+ end
126
+
127
+ #
128
+ # Get a topic type
129
+ #
130
+ # Get information about a topic type
131
+ #
132
+ # @param topic_type_name [String] Name of the topic type
133
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
134
+ # will be added to the HTTP request.
135
+ #
136
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
137
+ #
138
+ def get_with_http_info(topic_type_name, custom_headers = nil)
139
+ get_async(topic_type_name, custom_headers).value!
140
+ end
141
+
142
+ #
143
+ # Get a topic type
144
+ #
145
+ # Get information about a topic type
146
+ #
147
+ # @param topic_type_name [String] Name of the topic type
148
+ # @param [Hash{String => String}] A hash of custom headers that will be added
149
+ # to the HTTP request.
150
+ #
151
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
152
+ #
153
+ def get_async(topic_type_name, custom_headers = nil)
154
+ fail ArgumentError, 'topic_type_name is nil' if topic_type_name.nil?
155
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
156
+
157
+
158
+ request_headers = {}
159
+
160
+ # Set Headers
161
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
162
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
163
+ path_template = 'providers/Microsoft.EventGrid/topicTypes/{topicTypeName}'
164
+
165
+ request_url = @base_url || @client.base_url
166
+
167
+ options = {
168
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
169
+ path_params: {'topicTypeName' => topic_type_name},
170
+ query_params: {'api-version' => @client.api_version},
171
+ headers: request_headers.merge(custom_headers || {}),
172
+ base_url: request_url
173
+ }
174
+ promise = @client.make_request_async(:get, path_template, options)
175
+
176
+ promise = promise.then do |result|
177
+ http_response = result.response
178
+ status_code = http_response.status
179
+ response_content = http_response.body
180
+ unless status_code == 200
181
+ error_model = JSON.load(response_content)
182
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
183
+ end
184
+
185
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
186
+ # Deserialize Response
187
+ if status_code == 200
188
+ begin
189
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
190
+ result_mapper = Azure::ARM::EventGrid::Models::TopicTypeInfo.mapper()
191
+ result.body = @client.deserialize(result_mapper, parsed_response)
192
+ rescue Exception => e
193
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
194
+ end
195
+ end
196
+
197
+ result
198
+ end
199
+
200
+ promise.execute
201
+ end
202
+
203
+ #
204
+ # List event types
205
+ #
206
+ # List event types for a topic type
207
+ #
208
+ # @param topic_type_name [String] Name of the topic type
209
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
210
+ # will be added to the HTTP request.
211
+ #
212
+ # @return [EventTypesListResult] operation results.
213
+ #
214
+ def list_event_types(topic_type_name, custom_headers = nil)
215
+ response = list_event_types_async(topic_type_name, custom_headers).value!
216
+ response.body unless response.nil?
217
+ end
218
+
219
+ #
220
+ # List event types
221
+ #
222
+ # List event types for a topic type
223
+ #
224
+ # @param topic_type_name [String] Name of the topic type
225
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
226
+ # will be added to the HTTP request.
227
+ #
228
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
229
+ #
230
+ def list_event_types_with_http_info(topic_type_name, custom_headers = nil)
231
+ list_event_types_async(topic_type_name, custom_headers).value!
232
+ end
233
+
234
+ #
235
+ # List event types
236
+ #
237
+ # List event types for a topic type
238
+ #
239
+ # @param topic_type_name [String] Name of the topic type
240
+ # @param [Hash{String => String}] A hash of custom headers that will be added
241
+ # to the HTTP request.
242
+ #
243
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
244
+ #
245
+ def list_event_types_async(topic_type_name, custom_headers = nil)
246
+ fail ArgumentError, 'topic_type_name is nil' if topic_type_name.nil?
247
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
248
+
249
+
250
+ request_headers = {}
251
+
252
+ # Set Headers
253
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
254
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
255
+ path_template = 'providers/Microsoft.EventGrid/topicTypes/{topicTypeName}/eventTypes'
256
+
257
+ request_url = @base_url || @client.base_url
258
+
259
+ options = {
260
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
261
+ path_params: {'topicTypeName' => topic_type_name},
262
+ query_params: {'api-version' => @client.api_version},
263
+ headers: request_headers.merge(custom_headers || {}),
264
+ base_url: request_url
265
+ }
266
+ promise = @client.make_request_async(:get, path_template, options)
267
+
268
+ promise = promise.then do |result|
269
+ http_response = result.response
270
+ status_code = http_response.status
271
+ response_content = http_response.body
272
+ unless status_code == 200
273
+ error_model = JSON.load(response_content)
274
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
275
+ end
276
+
277
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
278
+ # Deserialize Response
279
+ if status_code == 200
280
+ begin
281
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
282
+ result_mapper = Azure::ARM::EventGrid::Models::EventTypesListResult.mapper()
283
+ result.body = @client.deserialize(result_mapper, parsed_response)
284
+ rescue Exception => e
285
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
286
+ end
287
+ end
288
+
289
+ result
290
+ end
291
+
292
+ promise.execute
293
+ end
294
+
295
+ end
296
+ end