lib/oci/core/virtual_network_client.rb
# Connects this local peering gateway (LPG) to another one in the same region.
#
# This operation must be called by the VCN administrator who is designated as
# the *requestor* in the peering relationship. The *acceptor* must implement
# an Identity and Access Management (IAM) policy that gives the requestor permission
# to connect to LPGs in the acceptor's compartment. Without that permission, this
# operation will fail. For more information, see
# [VCN Peering](https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm).
#
# @param [String] local_peering_gateway_id The OCID of the local peering gateway.
# @param [OCI::Core::Models::ConnectLocalPeeringGatewaysDetails] connect_local_peering_gateways_details Details regarding the local peering gateway to connect.
# @param [Hash] opts the optional parameters
# @option opts [OCI::Retry::RetryConfig] :retry_config The retry configuration to apply to this operation. If no key is provided then the service-level
#   retry configuration defined by {#retry_config} will be used. If an explicit `nil` value is provided then the operation will not retry
# @return [Response] A Response object with data of type nil
# @note Click [here](https://docs.cloud.oracle.com/en-us/iaas/tools/ruby-sdk-examples/latest/core/connect_local_peering_gateways.rb.html) to see an example of how to use connect_local_peering_gateways API.
Connects this local peering gateway (LPG) to another one in the same region.
This operation must be called by the VCN administrator who is designated as
the *requestor* in the peering relationship. The *acceptor* must implement
an Identity and Access Management (IAM) policy that gives the requestor permission
to connect to LPGs in the acceptor's compartment. Without that permission, this
operation will fail. For more information, see
[VCN Peering].
Connects this local peering gateway ( LPG ) to another one in the same region . This operation must be called by the VCN administrator who is designated as the * requestor * in the peering relationship . The * acceptor * must implement an Identity and Access Management ( IAM ) policy that gives the requestor permission to connect to LPGs in the acceptor ' s compartment . Without that permission this operation will fail . For more information see [ VCN Peering ] .
def connect_local_peering_gateways(local_peering_gateway_id, connect_local_peering_gateways_details, opts = {})
      logger.debug 'Calling operation VirtualNetworkClient#connect_local_peering_gateways.' if logger
      raise "Missing the required parameter 'local_peering_gateway_id' when calling connect_local_peering_gateways." if local_peering_gateway_id.nil?
      raise "Missing the required parameter 'connect_local_peering_gateways_details' when calling connect_local_peering_gateways." if connect_local_peering_gateways_details.nil?
      raise "Parameter value for 'local_peering_gateway_id' must not be blank" if OCI::Internal::Util.blank_string?(local_peering_gateway_id)
      path = '/localPeeringGateways/{localPeeringGatewayId}/actions/connect'.sub('{localPeeringGatewayId}', local_peering_gateway_id.to_s)
      operation_signing_strategy = :standard
      query_params = {}
      header_params = {}
      header_params[:accept] = 'application/json'
      header_params[:'content-type'] = 'application/json'
      post_body = @api_client.object_to_http_body(connect_local_peering_gateways_details)
      OCI::Retry.make_retrying_call(applicable_retry_config(opts), call_name: 'VirtualNetworkClient#connect_local_peering_gateways') 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
    end
def connect_local_peering_gateways ( local_peering_gateway_id , connect_local_peering_gateways_details , opts = { } ) logger . debug 'Calling operation VirtualNetworkClient#connect_local_peering_gateways.' if logger raise "Missing the required parameter 'local_peering_gateway_id' when calling connect_local_peering_gateways." if local_peering_gateway_id . nil? raise "Missing the required parameter 'connect_local_peering_gateways_details' when calling connect_local_peering_gateways." if connect_local_peering_gateways_details . nil? raise "Parameter value for 'local_peering_gateway_id' must not be blank" if OCI :: Internal :: Util . blank_string? ( local_peering_gateway_id ) path = '/localPeeringGateways/{localPeeringGatewayId}/actions/connect' . sub ( '{localPeeringGatewayId}' , local_peering_gateway_id . to_s ) operation_signing_strategy = :standard query_params = { } header_params = { } header_params [ :accept ] = 'application/json' header_params [ :' content-type ' ] = 'application/json' post_body = @api_client . object_to_http_body ( connect_local_peering_gateways_details ) OCI :: Retry . make_retrying_call ( applicable_retry_config ( opts ) , call_name : 'VirtualNetworkClient#connect_local_peering_gateways' ) 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 end
Connects this local peering gateway (LPG) to another one in the same region.
Connects this local peering gateway ( LPG ) to another one in the same region .
# rubocop:disable Style/NegatedIf # Query Params # Header Params # rubocop:enable Style/NegatedIf # rubocop:disable Metrics/BlockLength # rubocop:enable Metrics/BlockLength
A Response object with data of type nil
A Response object with data of type nil
Response
local_peering_gateway_id
<not_specific>
connect_local_peering_gateways_details
<not_specific>
opts
:retry_config The retry configuration to apply to this operation. If no key is provided then the service-level retry configuration defined by {#retry_config} will be used. If an explicit `nil` value is provided then the operation will not retry
: retry_config The retry configuration to apply to this operation . If no key is provided then the service - level retry configuration defined by { #retry_config } will be used . If an explicit ` nil ` value is provided then the operation will not retry
<not_specific>
opts the optional parameters
opts the optional parameters
note
Click [here] to see an example of how to use connect_local_peering_gateways API.
Click [ here ] to see an example of how to use connect_local_peering_gateways API .