Class: Azure::DataFactory::Mgmt::V2018_06_01::IntegrationRuntimeObjectMetadata
- Inherits:
-
Object
- Object
- Azure::DataFactory::Mgmt::V2018_06_01::IntegrationRuntimeObjectMetadata
- Includes:
- MsRestAzure
- Defined in:
- lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb
Overview
The Azure Data Factory V2 management API provides a RESTful set of web services that interact with Azure Data Factory V2 services.
Instance Attribute Summary collapse
-
#client ⇒ DataFactoryManagementClient
readonly
Reference to the DataFactoryManagementClient.
Instance Method Summary collapse
-
#begin_refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ SsisObjectMetadataStatusResponse
Refresh a SSIS integration runtime object metadata.
-
#begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ Concurrent::Promise
Refresh a SSIS integration runtime object metadata.
-
#begin_refresh_with_http_info(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Refresh a SSIS integration runtime object metadata.
-
#get(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ SsisObjectMetadataListResponse
Get a SSIS integration runtime object metadata by specified path.
-
#get_async(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ Concurrent::Promise
Get a SSIS integration runtime object metadata by specified path.
-
#get_with_http_info(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Get a SSIS integration runtime object metadata by specified path.
-
#initialize(client) ⇒ IntegrationRuntimeObjectMetadata
constructor
Creates and initializes a new instance of the IntegrationRuntimeObjectMetadata class.
-
#refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ SsisObjectMetadataStatusResponse
Refresh a SSIS integration runtime object metadata.
-
#refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
Constructor Details
#initialize(client) ⇒ IntegrationRuntimeObjectMetadata
Creates and initializes a new instance of the IntegrationRuntimeObjectMetadata class.
18 19 20 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 18 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ DataFactoryManagementClient (readonly)
Returns reference to the DataFactoryManagementClient.
23 24 25 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 23 def client @client end |
Instance Method Details
#begin_refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ SsisObjectMetadataStatusResponse
Refresh a SSIS integration runtime object metadata.
will be added to the HTTP request.
203 204 205 206 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 203 def begin_refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers:nil) response = begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ Concurrent::Promise
Refresh a SSIS integration runtime object metadata.
to the HTTP request.
234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 234 def begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:nil) fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90 fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil? fail ArgumentError, 'factory_name is nil' if factory_name.nil? fail ArgumentError, "'factory_name' should satisfy the constraint - 'MaxLength': '63'" if !factory_name.nil? && factory_name.length > 63 fail ArgumentError, "'factory_name' should satisfy the constraint - 'MinLength': '3'" if !factory_name.nil? && factory_name.length < 3 fail ArgumentError, "'factory_name' should satisfy the constraint - 'Pattern': '^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$'" if !factory_name.nil? && factory_name.match(Regexp.new('^^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$$')).nil? fail ArgumentError, 'integration_runtime_name is nil' if integration_runtime_name.nil? fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'MaxLength': '63'" if !integration_runtime_name.nil? && integration_runtime_name.length > 63 fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'MinLength': '3'" if !integration_runtime_name.nil? && integration_runtime_name.length < 3 fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'Pattern': '^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$'" if !integration_runtime_name.nil? && integration_runtime_name.match(Regexp.new('^^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$$')).nil? fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/refreshObjectMetadata' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'factoryName' => factory_name,'integrationRuntimeName' => integration_runtime_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 202 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::DataFactory::Mgmt::V2018_06_01::Models::SsisObjectMetadataStatusResponse.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#begin_refresh_with_http_info(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Refresh a SSIS integration runtime object metadata.
will be added to the HTTP request.
219 220 221 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 219 def begin_refresh_with_http_info(resource_group_name, factory_name, integration_runtime_name, custom_headers:nil) begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:custom_headers).value! end |
#get(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ SsisObjectMetadataListResponse
Get a SSIS integration runtime object metadata by specified path. The return is pageable metadata list.
getting a SSIS object metadata. will be added to the HTTP request.
83 84 85 86 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 83 def get(resource_group_name, factory_name, integration_runtime_name, get_metadata_request:nil, custom_headers:nil) response = get_async(resource_group_name, factory_name, integration_runtime_name, get_metadata_request:, custom_headers:custom_headers).value! response.body unless response.nil? end |
#get_async(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ Concurrent::Promise
Get a SSIS integration runtime object metadata by specified path. The return is pageable metadata list.
getting a SSIS object metadata. to the HTTP request.
120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 120 def get_async(resource_group_name, factory_name, integration_runtime_name, get_metadata_request:nil, custom_headers:nil) fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90 fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil? fail ArgumentError, 'factory_name is nil' if factory_name.nil? fail ArgumentError, "'factory_name' should satisfy the constraint - 'MaxLength': '63'" if !factory_name.nil? && factory_name.length > 63 fail ArgumentError, "'factory_name' should satisfy the constraint - 'MinLength': '3'" if !factory_name.nil? && factory_name.length < 3 fail ArgumentError, "'factory_name' should satisfy the constraint - 'Pattern': '^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$'" if !factory_name.nil? && factory_name.match(Regexp.new('^^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$$')).nil? fail ArgumentError, 'integration_runtime_name is nil' if integration_runtime_name.nil? fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'MaxLength': '63'" if !integration_runtime_name.nil? && integration_runtime_name.length > 63 fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'MinLength': '3'" if !integration_runtime_name.nil? && integration_runtime_name.length < 3 fail ArgumentError, "'integration_runtime_name' should satisfy the constraint - 'Pattern': '^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$'" if !integration_runtime_name.nil? && integration_runtime_name.match(Regexp.new('^^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$$')).nil? fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? # Serialize Request request_mapper = Azure::DataFactory::Mgmt::V2018_06_01::Models::GetSsisObjectMetadataRequest.mapper() request_content = @client.serialize(request_mapper, ) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/getObjectMetadata' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'factoryName' => factory_name,'integrationRuntimeName' => integration_runtime_name}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::DataFactory::Mgmt::V2018_06_01::Models::SsisObjectMetadataListResponse.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#get_with_http_info(resource_group_name, factory_name, integration_runtime_name, get_metadata_request: nil, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Get a SSIS integration runtime object metadata by specified path. The return is pageable metadata list.
getting a SSIS object metadata. will be added to the HTTP request.
102 103 104 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 102 def get_with_http_info(resource_group_name, factory_name, integration_runtime_name, get_metadata_request:nil, custom_headers:nil) get_async(resource_group_name, factory_name, integration_runtime_name, get_metadata_request:, custom_headers:custom_headers).value! end |
#refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ SsisObjectMetadataStatusResponse
Refresh a SSIS integration runtime object metadata.
will be added to the HTTP request.
36 37 38 39 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 36 def refresh(resource_group_name, factory_name, integration_runtime_name, custom_headers:nil) response = refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
response.
51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/2018-06-01/generated/azure_mgmt_data_factory/integration_runtime_object_metadata.rb', line 51 def refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:nil) # Send request promise = begin_refresh_async(resource_group_name, factory_name, integration_runtime_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| result_mapper = Azure::DataFactory::Mgmt::V2018_06_01::Models::SsisObjectMetadataStatusResponse.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |