Class: OCI::DisasterRecovery::DisasterRecoveryClient
- Inherits:
-
Object
- Object
- OCI::DisasterRecovery::DisasterRecoveryClient
- Defined in:
- lib/oci/disaster_recovery/disaster_recovery_client.rb
Overview
Use the Full Stack Disaster Recovery (DR) API to manage disaster recovery for business applications. Full Stack DR is an OCI disaster recovery orchestration and management service that provides comprehensive disaster recovery capabilities for all layers of an application stack, including infrastructure, middleware, database, and application.
Instance Attribute Summary collapse
-
#api_client ⇒ OCI::ApiClient
readonly
Client used to make HTTP requests.
-
#endpoint ⇒ String
readonly
Fully qualified endpoint URL.
-
#region ⇒ String
The region, which will usually correspond to a value in Regions::REGION_ENUM.
-
#retry_config ⇒ OCI::Retry::RetryConfig
readonly
The default retry configuration to apply to all operations in this service client.
Instance Method Summary collapse
-
#associate_dr_protection_group(associate_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Create an association between the DR protection group identified by drProtectionGroupId and another DR protection group.
-
#cancel_dr_plan_execution(cancel_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Cancel the DR plan execution identified by drPlanExecutionId.
-
#cancel_work_request(work_request_id, opts = {}) ⇒ Response
Cancel the work request identified by workRequestId.
-
#change_dr_protection_group_compartment(change_dr_protection_group_compartment_details, dr_protection_group_id, opts = {}) ⇒ Response
Move the DR protection group identified by drProtectionGroupId to a different compartment.
-
#create_dr_plan(create_dr_plan_details, opts = {}) ⇒ Response
Create a DR plan of the specified DR plan type.
-
#create_dr_plan_execution(create_dr_plan_execution_details, opts = {}) ⇒ Response
Execute a DR plan for a DR protection group.
-
#create_dr_protection_group(create_dr_protection_group_details, opts = {}) ⇒ Response
Create a DR protection group.
-
#delete_dr_plan(dr_plan_id, opts = {}) ⇒ Response
Delete the DR plan identified by drPlanId.
-
#delete_dr_plan_execution(dr_plan_execution_id, opts = {}) ⇒ Response
Delete the DR plan execution identified by drPlanExecutionId.
-
#delete_dr_protection_group(dr_protection_group_id, opts = {}) ⇒ Response
Delete the DR protection group identified by drProtectionGroupId.
-
#disassociate_dr_protection_group(disassociate_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Delete the association between the DR protection group identified by drProtectionGroupId.
-
#get_dr_plan(dr_plan_id, opts = {}) ⇒ Response
Get details for the DR plan identified by drPlanId.
-
#get_dr_plan_execution(dr_plan_execution_id, opts = {}) ⇒ Response
Get details for the DR plan execution identified by drPlanExecutionId.
-
#get_dr_protection_group(dr_protection_group_id, opts = {}) ⇒ Response
Get the DR protection group identified by drProtectionGroupId.
-
#get_work_request(work_request_id, opts = {}) ⇒ Response
Get the status of the work request identified by workRequestId.
-
#ignore_dr_plan_execution(ignore_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Ignore the failed group or step in DR plan execution identified by drPlanExecutionId and resume execution.
-
#initialize(config: nil, region: nil, endpoint: nil, signer: nil, proxy_settings: nil, retry_config: nil) ⇒ DisasterRecoveryClient
constructor
Creates a new DisasterRecoveryClient.
-
#list_dr_plan_executions(dr_protection_group_id, opts = {}) ⇒ Response
Get a summary list of all DR plan executions for a DR protection group.
-
#list_dr_plans(dr_protection_group_id, opts = {}) ⇒ Response
Get a summary list of all DR plans for a DR protection group.
-
#list_dr_protection_groups(compartment_id, opts = {}) ⇒ Response
Get a summary list of all DR protection groups in a compartment.
-
#list_work_request_errors(work_request_id, opts = {}) ⇒ Response
Get a list of work request errors for the work request identified by workRequestId.
-
#list_work_request_logs(work_request_id, opts = {}) ⇒ Response
Get a list of logs for the work request identified by workRequestId.
-
#list_work_requests(opts = {}) ⇒ Response
Lists the work requests in a compartment.
-
#logger ⇒ Logger
The logger for this client.
-
#pause_dr_plan_execution(pause_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Pause the DR plan execution identified by drPlanExecutionId.
-
#resume_dr_plan_execution(resume_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Resume the DR plan execution identified by drPlanExecutionId.
-
#retry_dr_plan_execution(retry_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Retry the failed group or step in DR plan execution identified by drPlanExecutionId and resume execution.
-
#update_dr_plan(update_dr_plan_details, dr_plan_id, opts = {}) ⇒ Response
Update the DR plan identified by drPlanId.
-
#update_dr_plan_execution(update_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Update the DR plan execution identified by drPlanExecutionId.
-
#update_dr_protection_group(update_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Update the DR protection group identified by drProtectionGroupId.
-
#update_dr_protection_group_role(update_dr_protection_group_role_details, dr_protection_group_id, opts = {}) ⇒ Response
Update the role of the DR protection group identified by drProtectionGroupId.
Constructor Details
#initialize(config: nil, region: nil, endpoint: nil, signer: nil, proxy_settings: nil, retry_config: nil) ⇒ DisasterRecoveryClient
Creates a new DisasterRecoveryClient. Notes: If a config is not specified, then the global OCI.config will be used.
This client is not thread-safe
Either a region or an endpoint must be specified. If an endpoint is specified, it will be used instead of the region. A region may be specified in the config or via or the region parameter. If specified in both, then the region parameter will be used.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 58 def initialize(config: nil, region: nil, endpoint: nil, signer: nil, proxy_settings: nil, retry_config: nil) # If the signer is an InstancePrincipalsSecurityTokenSigner or SecurityTokenSigner and no config was supplied (they are self-sufficient signers) # then create a dummy config to pass to the ApiClient constructor. If customers wish to create a client which uses instance principals # and has config (either populated programmatically or loaded from a file), they must construct that config themselves and then # pass it to this constructor. # # If there is no signer (or the signer is not an instance principals signer) and no config was supplied, this is not valid # so try and load the config from the default file. config = OCI::Config.validate_and_build_config_with_signer(config, signer) signer = OCI::Signer.config_file_auth_builder(config) if signer.nil? @api_client = OCI::ApiClient.new(config, signer, proxy_settings: proxy_settings) @retry_config = retry_config if endpoint @endpoint = endpoint + '/20220125' else region ||= config.region region ||= signer.region if signer.respond_to?(:region) self.region = region end logger.info "DisasterRecoveryClient endpoint set to '#{@endpoint}'." if logger end |
Instance Attribute Details
#api_client ⇒ OCI::ApiClient (readonly)
Client used to make HTTP requests.
18 19 20 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 18 def api_client @api_client end |
#endpoint ⇒ String (readonly)
Fully qualified endpoint URL
22 23 24 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 22 def endpoint @endpoint end |
#region ⇒ String
The region, which will usually correspond to a value in Regions::REGION_ENUM.
32 33 34 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 32 def region @region end |
#retry_config ⇒ OCI::Retry::RetryConfig (readonly)
The default retry configuration to apply to all operations in this service client. This can be overridden on a per-operation basis. The default retry configuration value is nil
, which means that an operation will not perform any retries
28 29 30 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 28 def retry_config @retry_config end |
Instance Method Details
#associate_dr_protection_group(associate_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use associate_dr_protection_group API.
Create an association between the DR protection group identified by drProtectionGroupId and another DR protection group.
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 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 133 def associate_dr_protection_group(associate_dr_protection_group_details, dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#associate_dr_protection_group.' if logger raise "Missing the required parameter 'associate_dr_protection_group_details' when calling associate_dr_protection_group." if associate_dr_protection_group_details.nil? raise "Missing the required parameter 'dr_protection_group_id' when calling associate_dr_protection_group." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}/actions/associate'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(associate_dr_protection_group_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#associate_dr_protection_group') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#cancel_dr_plan_execution(cancel_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use cancel_dr_plan_execution API.
Cancel the DR plan execution identified by drPlanExecutionId.
207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 207 def cancel_dr_plan_execution(cancel_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#cancel_dr_plan_execution.' if logger raise "Missing the required parameter 'cancel_dr_plan_execution_details' when calling cancel_dr_plan_execution." if cancel_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling cancel_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}/actions/cancel'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(cancel_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#cancel_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#cancel_work_request(work_request_id, opts = {}) ⇒ Response
Click here to see an example of how to use cancel_work_request API.
Cancel the work request identified by workRequestId.
274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 274 def cancel_work_request(work_request_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#cancel_work_request.' if logger raise "Missing the required parameter 'work_request_id' when calling cancel_work_request." if work_request_id.nil? raise "Parameter value for 'work_request_id' must not be blank" if OCI::Internal::Util.blank_string?(work_request_id) path = '/workRequests/{workRequestId}'.sub('{workRequestId}', work_request_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#cancel_work_request') do @api_client.call_api( :DELETE, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#change_dr_protection_group_compartment(change_dr_protection_group_compartment_details, dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use change_dr_protection_group_compartment API.
Move the DR protection group identified by drProtectionGroupId to a different compartment.
345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 345 def change_dr_protection_group_compartment(change_dr_protection_group_compartment_details, dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#change_dr_protection_group_compartment.' if logger raise "Missing the required parameter 'change_dr_protection_group_compartment_details' when calling change_dr_protection_group_compartment." if change_dr_protection_group_compartment_details.nil? raise "Missing the required parameter 'dr_protection_group_id' when calling change_dr_protection_group_compartment." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}/actions/changeCompartment'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(change_dr_protection_group_compartment_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#change_dr_protection_group_compartment') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#create_dr_plan(create_dr_plan_details, opts = {}) ⇒ Response
Click here to see an example of how to use create_dr_plan API.
Create a DR plan of the specified DR plan type.
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 409 def create_dr_plan(create_dr_plan_details, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#create_dr_plan.' if logger raise "Missing the required parameter 'create_dr_plan_details' when calling create_dr_plan." if create_dr_plan_details.nil? path = '/drPlans' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(create_dr_plan_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#create_dr_plan') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlan' ) end # rubocop:enable Metrics/BlockLength end |
#create_dr_plan_execution(create_dr_plan_execution_details, opts = {}) ⇒ Response
Click here to see an example of how to use create_dr_plan_execution API.
Execute a DR plan for a DR protection group.
471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 471 def create_dr_plan_execution(create_dr_plan_execution_details, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#create_dr_plan_execution.' if logger raise "Missing the required parameter 'create_dr_plan_execution_details' when calling create_dr_plan_execution." if create_dr_plan_execution_details.nil? path = '/drPlanExecutions' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(create_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#create_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlanExecution' ) end # rubocop:enable Metrics/BlockLength end |
#create_dr_protection_group(create_dr_protection_group_details, opts = {}) ⇒ Response
Click here to see an example of how to use create_dr_protection_group API.
Create a DR protection group.
533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 533 def create_dr_protection_group(create_dr_protection_group_details, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#create_dr_protection_group.' if logger raise "Missing the required parameter 'create_dr_protection_group_details' when calling create_dr_protection_group." if create_dr_protection_group_details.nil? path = '/drProtectionGroups' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(create_dr_protection_group_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#create_dr_protection_group') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrProtectionGroup' ) end # rubocop:enable Metrics/BlockLength end |
#delete_dr_plan(dr_plan_id, opts = {}) ⇒ Response
Click here to see an example of how to use delete_dr_plan API.
Delete the DR plan identified by drPlanId.
598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 598 def delete_dr_plan(dr_plan_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#delete_dr_plan.' if logger raise "Missing the required parameter 'dr_plan_id' when calling delete_dr_plan." if dr_plan_id.nil? raise "Parameter value for 'dr_plan_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_id) path = '/drPlans/{drPlanId}'.sub('{drPlanId}', dr_plan_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#delete_dr_plan') do @api_client.call_api( :DELETE, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#delete_dr_plan_execution(dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use delete_dr_plan_execution API.
Delete the DR plan execution identified by drPlanExecutionId.
662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 662 def delete_dr_plan_execution(dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#delete_dr_plan_execution.' if logger raise "Missing the required parameter 'dr_plan_execution_id' when calling delete_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#delete_dr_plan_execution') do @api_client.call_api( :DELETE, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#delete_dr_protection_group(dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use delete_dr_protection_group API.
Delete the DR protection group identified by drProtectionGroupId.
726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 726 def delete_dr_protection_group(dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#delete_dr_protection_group.' if logger raise "Missing the required parameter 'dr_protection_group_id' when calling delete_dr_protection_group." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#delete_dr_protection_group') do @api_client.call_api( :DELETE, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#disassociate_dr_protection_group(disassociate_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use disassociate_dr_protection_group API.
Delete the association between the DR protection group identified by drProtectionGroupId. and its peer DR protection group.
799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 799 def disassociate_dr_protection_group(disassociate_dr_protection_group_details, dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#disassociate_dr_protection_group.' if logger raise "Missing the required parameter 'disassociate_dr_protection_group_details' when calling disassociate_dr_protection_group." if disassociate_dr_protection_group_details.nil? raise "Missing the required parameter 'dr_protection_group_id' when calling disassociate_dr_protection_group." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}/actions/disassociate'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(disassociate_dr_protection_group_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#disassociate_dr_protection_group') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#get_dr_plan(dr_plan_id, opts = {}) ⇒ Response
Click here to see an example of how to use get_dr_plan API.
Get details for the DR plan identified by drPlanId.
860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 860 def get_dr_plan(dr_plan_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#get_dr_plan.' if logger raise "Missing the required parameter 'dr_plan_id' when calling get_dr_plan." if dr_plan_id.nil? raise "Parameter value for 'dr_plan_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_id) path = '/drPlans/{drPlanId}'.sub('{drPlanId}', dr_plan_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#get_dr_plan') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlan' ) end # rubocop:enable Metrics/BlockLength end |
#get_dr_plan_execution(dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use get_dr_plan_execution API.
Get details for the DR plan execution identified by drPlanExecutionId.
918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 918 def get_dr_plan_execution(dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#get_dr_plan_execution.' if logger raise "Missing the required parameter 'dr_plan_execution_id' when calling get_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#get_dr_plan_execution') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlanExecution' ) end # rubocop:enable Metrics/BlockLength end |
#get_dr_protection_group(dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use get_dr_protection_group API.
Get the DR protection group identified by drProtectionGroupId.
976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 976 def get_dr_protection_group(dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#get_dr_protection_group.' if logger raise "Missing the required parameter 'dr_protection_group_id' when calling get_dr_protection_group." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#get_dr_protection_group') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrProtectionGroup' ) end # rubocop:enable Metrics/BlockLength end |
#get_work_request(work_request_id, opts = {}) ⇒ Response
Click here to see an example of how to use get_work_request API.
Get the status of the work request identified by workRequestId.
1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1034 def get_work_request(work_request_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#get_work_request.' if logger raise "Missing the required parameter 'work_request_id' when calling get_work_request." if work_request_id.nil? raise "Parameter value for 'work_request_id' must not be blank" if OCI::Internal::Util.blank_string?(work_request_id) path = '/workRequests/{workRequestId}'.sub('{workRequestId}', work_request_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#get_work_request') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::WorkRequest' ) end # rubocop:enable Metrics/BlockLength end |
#ignore_dr_plan_execution(ignore_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use ignore_dr_plan_execution API.
Ignore the failed group or step in DR plan execution identified by drPlanExecutionId and resume execution.
1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1105 def ignore_dr_plan_execution(ignore_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#ignore_dr_plan_execution.' if logger raise "Missing the required parameter 'ignore_dr_plan_execution_details' when calling ignore_dr_plan_execution." if ignore_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling ignore_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}/actions/ignore'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(ignore_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#ignore_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#list_dr_plan_executions(dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use list_dr_plan_executions API.
Get a summary list of all DR plan executions for a DR protection group.
1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1200 def list_dr_plan_executions(dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_dr_plan_executions.' if logger raise "Missing the required parameter 'dr_protection_group_id' when calling list_dr_plan_executions." if dr_protection_group_id.nil? if opts[:lifecycle_state] && !OCI::DisasterRecovery::Models::DR_PLAN_EXECUTION_LIFECYCLE_STATE_ENUM.include?(opts[:lifecycle_state]) raise 'Invalid value for "lifecycle_state", must be one of the values in OCI::DisasterRecovery::Models::DR_PLAN_EXECUTION_LIFECYCLE_STATE_ENUM.' end if opts[:dr_plan_execution_type] && !OCI::DisasterRecovery::Models::DR_PLAN_EXECUTION_TYPE_ENUM.include?(opts[:dr_plan_execution_type]) raise 'Invalid value for "dr_plan_execution_type", must be one of the values in OCI::DisasterRecovery::Models::DR_PLAN_EXECUTION_TYPE_ENUM.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end if opts[:sort_by] && !%w[timeCreated displayName].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeCreated, displayName.' end path = '/drPlanExecutions' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:drProtectionGroupId] = dr_protection_group_id query_params[:lifecycleState] = opts[:lifecycle_state] if opts[:lifecycle_state] query_params[:drPlanExecutionId] = opts[:dr_plan_execution_id] if opts[:dr_plan_execution_id] query_params[:drPlanExecutionType] = opts[:dr_plan_execution_type] if opts[:dr_plan_execution_type] query_params[:displayName] = opts[:display_name] if opts[:display_name] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:page] = opts[:page] if opts[:page] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_dr_plan_executions') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlanExecutionCollection' ) end # rubocop:enable Metrics/BlockLength end |
#list_dr_plans(dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use list_dr_plans API.
Get a summary list of all DR plans for a DR protection group.
1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1316 def list_dr_plans(dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_dr_plans.' if logger raise "Missing the required parameter 'dr_protection_group_id' when calling list_dr_plans." if dr_protection_group_id.nil? if opts[:lifecycle_state] && !OCI::DisasterRecovery::Models::DR_PLAN_LIFECYCLE_STATE_ENUM.include?(opts[:lifecycle_state]) raise 'Invalid value for "lifecycle_state", must be one of the values in OCI::DisasterRecovery::Models::DR_PLAN_LIFECYCLE_STATE_ENUM.' end if opts[:dr_plan_type] && !OCI::DisasterRecovery::Models::DR_PLAN_TYPE_ENUM.include?(opts[:dr_plan_type]) raise 'Invalid value for "dr_plan_type", must be one of the values in OCI::DisasterRecovery::Models::DR_PLAN_TYPE_ENUM.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end if opts[:sort_by] && !%w[timeCreated displayName].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeCreated, displayName.' end path = '/drPlans' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:drProtectionGroupId] = dr_protection_group_id query_params[:lifecycleState] = opts[:lifecycle_state] if opts[:lifecycle_state] query_params[:drPlanId] = opts[:dr_plan_id] if opts[:dr_plan_id] query_params[:drPlanType] = opts[:dr_plan_type] if opts[:dr_plan_type] query_params[:displayName] = opts[:display_name] if opts[:display_name] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:page] = opts[:page] if opts[:page] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_dr_plans') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrPlanCollection' ) end # rubocop:enable Metrics/BlockLength end |
#list_dr_protection_groups(compartment_id, opts = {}) ⇒ Response
Click here to see an example of how to use list_dr_protection_groups API.
Get a summary list of all DR protection groups in a compartment.
1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1434 def list_dr_protection_groups(compartment_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_dr_protection_groups.' if logger raise "Missing the required parameter 'compartment_id' when calling list_dr_protection_groups." if compartment_id.nil? if opts[:lifecycle_state] && !OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_LIFECYCLE_STATE_ENUM.include?(opts[:lifecycle_state]) raise 'Invalid value for "lifecycle_state", must be one of the values in OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_LIFECYCLE_STATE_ENUM.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end if opts[:sort_by] && !%w[timeCreated displayName].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeCreated, displayName.' end if opts[:role] && !OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_ROLE_ENUM.include?(opts[:role]) raise 'Invalid value for "role", must be one of the values in OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_ROLE_ENUM.' end if opts[:lifecycle_sub_state] && !OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_LIFECYCLE_SUB_STATE_ENUM.include?(opts[:lifecycle_sub_state]) raise 'Invalid value for "lifecycle_sub_state", must be one of the values in OCI::DisasterRecovery::Models::DR_PROTECTION_GROUP_LIFECYCLE_SUB_STATE_ENUM.' end path = '/drProtectionGroups' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:compartmentId] = compartment_id query_params[:lifecycleState] = opts[:lifecycle_state] if opts[:lifecycle_state] query_params[:drProtectionGroupId] = opts[:dr_protection_group_id] if opts[:dr_protection_group_id] query_params[:displayName] = opts[:display_name] if opts[:display_name] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:page] = opts[:page] if opts[:page] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] query_params[:role] = opts[:role] if opts[:role] query_params[:lifecycleSubState] = opts[:lifecycle_sub_state] if opts[:lifecycle_sub_state] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_dr_protection_groups') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::DrProtectionGroupCollection' ) end # rubocop:enable Metrics/BlockLength end |
#list_work_request_errors(work_request_id, opts = {}) ⇒ Response
Click here to see an example of how to use list_work_request_errors API.
Get a list of work request errors for the work request identified by workRequestId.
1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1543 def list_work_request_errors(work_request_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_work_request_errors.' if logger raise "Missing the required parameter 'work_request_id' when calling list_work_request_errors." if work_request_id.nil? if opts[:sort_by] && !%w[timeAccepted].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeAccepted.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end raise "Parameter value for 'work_request_id' must not be blank" if OCI::Internal::Util.blank_string?(work_request_id) path = '/workRequests/{workRequestId}/errors'.sub('{workRequestId}', work_request_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:page] = opts[:page] if opts[:page] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_work_request_errors') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::WorkRequestErrorCollection' ) end # rubocop:enable Metrics/BlockLength end |
#list_work_request_logs(work_request_id, opts = {}) ⇒ Response
Click here to see an example of how to use list_work_request_logs API.
Get a list of logs for the work request identified by workRequestId.
1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1635 def list_work_request_logs(work_request_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_work_request_logs.' if logger raise "Missing the required parameter 'work_request_id' when calling list_work_request_logs." if work_request_id.nil? if opts[:sort_by] && !%w[timeAccepted].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeAccepted.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end raise "Parameter value for 'work_request_id' must not be blank" if OCI::Internal::Util.blank_string?(work_request_id) path = '/workRequests/{workRequestId}/logs'.sub('{workRequestId}', work_request_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:page] = opts[:page] if opts[:page] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_work_request_logs') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::WorkRequestLogEntryCollection' ) end # rubocop:enable Metrics/BlockLength end |
#list_work_requests(opts = {}) ⇒ Response
Click here to see an example of how to use list_work_requests API.
Lists the work requests in a compartment.
1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1737 def list_work_requests(opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#list_work_requests.' if logger if opts[:status] && !OCI::DisasterRecovery::Models::OPERATION_STATUS_ENUM.include?(opts[:status]) raise 'Invalid value for "status", must be one of the values in OCI::DisasterRecovery::Models::OPERATION_STATUS_ENUM.' end if opts[:sort_order] && !OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.include?(opts[:sort_order]) raise 'Invalid value for "sort_order", must be one of the values in OCI::DisasterRecovery::Models::SORT_ORDER_ENUM.' end if opts[:sort_by] && !%w[timeAccepted].include?(opts[:sort_by]) raise 'Invalid value for "sort_by", must be one of timeAccepted.' end path = '/workRequests' operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} query_params[:compartmentId] = opts[:compartment_id] if opts[:compartment_id] query_params[:workRequestId] = opts[:work_request_id] if opts[:work_request_id] query_params[:status] = opts[:status] if opts[:status] query_params[:resourceId] = opts[:resource_id] if opts[:resource_id] query_params[:page] = opts[:page] if opts[:page] query_params[:limit] = opts[:limit] if opts[:limit] query_params[:sortOrder] = opts[:sort_order] if opts[:sort_order] query_params[:sortBy] = opts[:sort_by] if opts[:sort_by] # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = nil # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#list_work_requests') do @api_client.call_api( :GET, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body, return_type: 'OCI::DisasterRecovery::Models::WorkRequestSummaryCollection' ) end # rubocop:enable Metrics/BlockLength end |
#logger ⇒ Logger
Returns The logger for this client. May be nil.
97 98 99 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 97 def logger @api_client.config.logger end |
#pause_dr_plan_execution(pause_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use pause_dr_plan_execution API.
Pause the DR plan execution identified by drPlanExecutionId.
1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1826 def pause_dr_plan_execution(pause_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#pause_dr_plan_execution.' if logger raise "Missing the required parameter 'pause_dr_plan_execution_details' when calling pause_dr_plan_execution." if pause_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling pause_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}/actions/pause'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(pause_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#pause_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#resume_dr_plan_execution(resume_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use resume_dr_plan_execution API.
Resume the DR plan execution identified by drPlanExecutionId.
1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1900 def resume_dr_plan_execution(resume_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#resume_dr_plan_execution.' if logger raise "Missing the required parameter 'resume_dr_plan_execution_details' when calling resume_dr_plan_execution." if resume_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling resume_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}/actions/resume'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(resume_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#resume_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#retry_dr_plan_execution(retry_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use retry_dr_plan_execution API.
Retry the failed group or step in DR plan execution identified by drPlanExecutionId and resume execution.
1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 1974 def retry_dr_plan_execution(retry_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#retry_dr_plan_execution.' if logger raise "Missing the required parameter 'retry_dr_plan_execution_details' when calling retry_dr_plan_execution." if retry_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling retry_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}/actions/retry'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(retry_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#retry_dr_plan_execution') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#update_dr_plan(update_dr_plan_details, dr_plan_id, opts = {}) ⇒ Response
Click here to see an example of how to use update_dr_plan API.
Update the DR plan identified by drPlanId.
2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 2042 def update_dr_plan(update_dr_plan_details, dr_plan_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#update_dr_plan.' if logger raise "Missing the required parameter 'update_dr_plan_details' when calling update_dr_plan." if update_dr_plan_details.nil? raise "Missing the required parameter 'dr_plan_id' when calling update_dr_plan." if dr_plan_id.nil? raise "Parameter value for 'dr_plan_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_id) path = '/drPlans/{drPlanId}'.sub('{drPlanId}', dr_plan_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = @api_client.object_to_http_body(update_dr_plan_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#update_dr_plan') do @api_client.call_api( :PUT, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#update_dr_plan_execution(update_dr_plan_execution_details, dr_plan_execution_id, opts = {}) ⇒ Response
Click here to see an example of how to use update_dr_plan_execution API.
Update the DR plan execution identified by drPlanExecutionId.
2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 2108 def update_dr_plan_execution(update_dr_plan_execution_details, dr_plan_execution_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#update_dr_plan_execution.' if logger raise "Missing the required parameter 'update_dr_plan_execution_details' when calling update_dr_plan_execution." if update_dr_plan_execution_details.nil? raise "Missing the required parameter 'dr_plan_execution_id' when calling update_dr_plan_execution." if dr_plan_execution_id.nil? raise "Parameter value for 'dr_plan_execution_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_plan_execution_id) path = '/drPlanExecutions/{drPlanExecutionId}'.sub('{drPlanExecutionId}', dr_plan_execution_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = @api_client.object_to_http_body(update_dr_plan_execution_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#update_dr_plan_execution') do @api_client.call_api( :PUT, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#update_dr_protection_group(update_dr_protection_group_details, dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use update_dr_protection_group API.
Update the DR protection group identified by drProtectionGroupId.
2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 2174 def update_dr_protection_group(update_dr_protection_group_details, dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#update_dr_protection_group.' if logger raise "Missing the required parameter 'update_dr_protection_group_details' when calling update_dr_protection_group." if update_dr_protection_group_details.nil? raise "Missing the required parameter 'dr_protection_group_id' when calling update_dr_protection_group." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf post_body = @api_client.object_to_http_body(update_dr_protection_group_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#update_dr_protection_group') do @api_client.call_api( :PUT, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |
#update_dr_protection_group_role(update_dr_protection_group_role_details, dr_protection_group_id, opts = {}) ⇒ Response
Click here to see an example of how to use update_dr_protection_group_role API.
Update the role of the DR protection group identified by drProtectionGroupId.
2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 |
# File 'lib/oci/disaster_recovery/disaster_recovery_client.rb', line 2246 def update_dr_protection_group_role(update_dr_protection_group_role_details, dr_protection_group_id, opts = {}) logger.debug 'Calling operation DisasterRecoveryClient#update_dr_protection_group_role.' if logger raise "Missing the required parameter 'update_dr_protection_group_role_details' when calling update_dr_protection_group_role." if update_dr_protection_group_role_details.nil? raise "Missing the required parameter 'dr_protection_group_id' when calling update_dr_protection_group_role." if dr_protection_group_id.nil? raise "Parameter value for 'dr_protection_group_id' must not be blank" if OCI::Internal::Util.blank_string?(dr_protection_group_id) path = '/drProtectionGroups/{drProtectionGroupId}/actions/updateRole'.sub('{drProtectionGroupId}', dr_protection_group_id.to_s) operation_signing_strategy = :standard # rubocop:disable Style/NegatedIf # Query Params query_params = {} # Header Params header_params = {} header_params[:accept] = 'application/json' header_params[:'content-type'] = 'application/json' header_params[:'if-match'] = opts[:if_match] if opts[:if_match] header_params[:'opc-retry-token'] = opts[:opc_retry_token] if opts[:opc_retry_token] header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id] # rubocop:enable Style/NegatedIf header_params[:'opc-retry-token'] ||= OCI::Retry.generate_opc_retry_token post_body = @api_client.object_to_http_body(update_dr_protection_group_role_details) # rubocop:disable Metrics/BlockLength OCI::Retry.(applicable_retry_config(opts), call_name: 'DisasterRecoveryClient#update_dr_protection_group_role') do @api_client.call_api( :POST, path, endpoint, header_params: header_params, query_params: query_params, operation_signing_strategy: operation_signing_strategy, body: post_body ) end # rubocop:enable Metrics/BlockLength end |