lib/google/cloud/compute/v1/target_pools/rest/grpc_transcoding.rb in google-cloud-compute-v1-0.1.0 vs lib/google/cloud/compute/v1/target_pools/rest/grpc_transcoding.rb in google-cloud-compute-v1-0.2.0

- old
+ new

@@ -31,10 +31,11 @@ # Uri, Body, Query string parameters def transcode_add_health_check request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools/#{request_pb.target_pool}/addHealthCheck" body = request_pb.target_pools_add_health_check_request_resource.to_json query_string_params = {} + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end # @param request_pb [::Google::Cloud::Compute::V1::AddInstanceTargetPoolRequest] @@ -43,10 +44,11 @@ # Uri, Body, Query string parameters def transcode_add_instance request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools/#{request_pb.target_pool}/addInstance" body = request_pb.target_pools_add_instance_request_resource.to_json query_string_params = {} + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end # @param request_pb [::Google::Cloud::Compute::V1::AggregatedListTargetPoolsRequest] @@ -110,10 +112,11 @@ # Uri, Body, Query string parameters def transcode_insert request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools" body = request_pb.target_pool_resource.to_json query_string_params = {} + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end # @param request_pb [::Google::Cloud::Compute::V1::ListTargetPoolsRequest] @@ -139,10 +142,11 @@ # Uri, Body, Query string parameters def transcode_remove_health_check request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools/#{request_pb.target_pool}/removeHealthCheck" body = request_pb.target_pools_remove_health_check_request_resource.to_json query_string_params = {} + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end # @param request_pb [::Google::Cloud::Compute::V1::RemoveInstanceTargetPoolRequest] @@ -151,10 +155,11 @@ # Uri, Body, Query string parameters def transcode_remove_instance request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools/#{request_pb.target_pool}/removeInstance" body = request_pb.target_pools_remove_instance_request_resource.to_json query_string_params = {} + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end # @param request_pb [::Google::Cloud::Compute::V1::SetBackupTargetPoolRequest] @@ -163,9 +168,11 @@ # Uri, Body, Query string parameters def transcode_set_backup request_pb uri = "/compute/v1/projects/#{request_pb.project}/regions/#{request_pb.region}/targetPools/#{request_pb.target_pool}/setBackup" body = request_pb.target_reference_resource.to_json query_string_params = {} + query_string_params["failoverRatio"] = request_pb.failover_ratio.to_s if request_pb.has_failover_ratio? + query_string_params["requestId"] = request_pb.request_id.to_s if request_pb.has_request_id? [uri, body, query_string_params] end extend self end