Class: Google::Cloud::AIPlatform::V1::PipelineService::Rest::Client
- Inherits:
-
Object
- Object
- Google::Cloud::AIPlatform::V1::PipelineService::Rest::Client
- Includes:
- Paths
- Defined in:
- lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb
Overview
REST client for the PipelineService service.
A service for creating and managing Vertex AI's pipelines. This includes both
TrainingPipeline
resources (used for AutoML and custom training) and
PipelineJob
resources (used for Vertex AI Pipelines).
Defined Under Namespace
Classes: Configuration
Instance Attribute Summary collapse
-
#iam_policy_client ⇒ Google::Iam::V1::IAMPolicy::Rest::Client
readonly
Get the associated client for mix-in of the IAMPolicy.
-
#location_client ⇒ Google::Cloud::Location::Locations::Rest::Client
readonly
Get the associated client for mix-in of the Locations.
-
#operations_client ⇒ ::Google::Cloud::AIPlatform::V1::PipelineService::Rest::Operations
readonly
Get the associated client for long-running operations.
Class Method Summary collapse
-
.configure {|config| ... } ⇒ Client::Configuration
Configure the PipelineService Client class.
Instance Method Summary collapse
-
#batch_cancel_pipeline_jobs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Batch cancel PipelineJobs.
-
#batch_delete_pipeline_jobs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Batch deletes PipelineJobs The Operation is atomic.
-
#cancel_pipeline_job(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Cancels a PipelineJob.
-
#cancel_training_pipeline(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Cancels a TrainingPipeline.
-
#configure {|config| ... } ⇒ Client::Configuration
Configure the PipelineService Client instance.
-
#create_pipeline_job(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob
Creates a PipelineJob.
-
#create_training_pipeline(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline
Creates a TrainingPipeline.
-
#delete_pipeline_job(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Deletes a PipelineJob.
-
#delete_training_pipeline(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Deletes a TrainingPipeline.
-
#get_pipeline_job(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob
Gets a PipelineJob.
-
#get_training_pipeline(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline
Gets a TrainingPipeline.
-
#initialize {|config| ... } ⇒ Client
constructor
Create a new PipelineService REST client object.
-
#list_pipeline_jobs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::PipelineJob>
Lists PipelineJobs in a Location.
-
#list_training_pipelines(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::TrainingPipeline>
Lists TrainingPipelines in a Location.
-
#universe_domain ⇒ String
The effective universe domain.
Methods included from Paths
#artifact_path, #context_path, #custom_job_path, #endpoint_path, #execution_path, #location_path, #model_path, #network_path, #pipeline_job_path, #training_pipeline_path
Constructor Details
#initialize {|config| ... } ⇒ Client
Create a new PipelineService REST client object.
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 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 130 def initialize # Create the configuration object @config = Configuration.new Client.configure # Yield the configuration if needed yield @config if block_given? # Create credentials credentials = @config.credentials # Use self-signed JWT if the endpoint is unchanged from default, # but only if the default endpoint does not have a region prefix. enable_self_signed_jwt = @config.endpoint.nil? || (@config.endpoint == Configuration::DEFAULT_ENDPOINT && !@config.endpoint.split(".").first.include?("-")) credentials ||= Credentials.default scope: @config.scope, enable_self_signed_jwt: enable_self_signed_jwt if credentials.is_a?(::String) || credentials.is_a?(::Hash) credentials = Credentials.new credentials, scope: @config.scope end @quota_project_id = @config.quota_project @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id @operations_client = ::Google::Cloud::AIPlatform::V1::PipelineService::Rest::Operations.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @config.endpoint config.universe_domain = @config.universe_domain end @pipeline_service_stub = ::Google::Cloud::AIPlatform::V1::PipelineService::Rest::ServiceStub.new( endpoint: @config.endpoint, endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, universe_domain: @config.universe_domain, credentials: credentials ) @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @pipeline_service_stub.endpoint config.universe_domain = @pipeline_service_stub.universe_domain config.bindings_override = @config.bindings_override end @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @pipeline_service_stub.endpoint config.universe_domain = @pipeline_service_stub.universe_domain config.bindings_override = @config.bindings_override end end |
Instance Attribute Details
#iam_policy_client ⇒ Google::Iam::V1::IAMPolicy::Rest::Client (readonly)
Get the associated client for mix-in of the IAMPolicy.
203 204 205 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 203 def iam_policy_client @iam_policy_client end |
#location_client ⇒ Google::Cloud::Location::Locations::Rest::Client (readonly)
Get the associated client for mix-in of the Locations.
196 197 198 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 196 def location_client @location_client end |
#operations_client ⇒ ::Google::Cloud::AIPlatform::V1::PipelineService::Rest::Operations (readonly)
Get the associated client for long-running operations.
189 190 191 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 189 def operations_client @operations_client end |
Class Method Details
.configure {|config| ... } ⇒ Client::Configuration
Configure the PipelineService Client class.
See Configuration for a description of the configuration fields.
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 68 def self.configure @configure ||= begin namespace = ["Google", "Cloud", "AIPlatform", "V1"] parent_config = while namespace.any? parent_name = namespace.join "::" parent_const = const_get parent_name break parent_const.configure if parent_const.respond_to? :configure namespace.pop end default_config = Client::Configuration.new parent_config default_config end yield @configure if block_given? @configure end |
Instance Method Details
#batch_cancel_pipeline_jobs(request, options = nil) ⇒ ::Gapic::Operation #batch_cancel_pipeline_jobs(parent: nil, names: nil) ⇒ ::Gapic::Operation
Batch cancel PipelineJobs. Firstly the server will check if all the jobs are in non-terminal states, and skip the jobs that are already terminated. If the operation failed, none of the pipeline jobs are cancelled. The server will poll the states of all the pipeline jobs periodically to check the cancellation status. This operation will return an LRO.
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 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 1325 def batch_cancel_pipeline_jobs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::BatchCancelPipelineJobsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.batch_cancel_pipeline_jobs..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.batch_cancel_pipeline_jobs.timeout, metadata: , retry_policy: @config.rpcs.batch_cancel_pipeline_jobs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.batch_cancel_pipeline_jobs request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#batch_delete_pipeline_jobs(request, options = nil) ⇒ ::Gapic::Operation #batch_delete_pipeline_jobs(parent: nil, names: nil) ⇒ ::Gapic::Operation
Batch deletes PipelineJobs The Operation is atomic. If it fails, none of the PipelineJobs are deleted. If it succeeds, all of the PipelineJobs are deleted.
1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 1133 def batch_delete_pipeline_jobs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::BatchDeletePipelineJobsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.batch_delete_pipeline_jobs..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.batch_delete_pipeline_jobs.timeout, metadata: , retry_policy: @config.rpcs.batch_delete_pipeline_jobs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.batch_delete_pipeline_jobs request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#cancel_pipeline_job(request, options = nil) ⇒ ::Google::Protobuf::Empty #cancel_pipeline_job(name: nil) ⇒ ::Google::Protobuf::Empty
Cancels a PipelineJob.
Starts asynchronous cancellation on the PipelineJob. The server
makes a best effort to cancel the pipeline, but success is not
guaranteed. Clients can use
PipelineService.GetPipelineJob
or other methods to check whether the cancellation succeeded or whether the
pipeline completed despite cancellation. On successful cancellation,
the PipelineJob is not deleted; instead it becomes a pipeline with
a PipelineJob.error value
with a google.rpc.Status.code of 1, corresponding
to Code.CANCELLED
, and
PipelineJob.state is set to
CANCELLED
.
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 1261 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 1227 def cancel_pipeline_job request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CancelPipelineJobRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.cancel_pipeline_job..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.cancel_pipeline_job.timeout, metadata: , retry_policy: @config.rpcs.cancel_pipeline_job.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.cancel_pipeline_job request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#cancel_training_pipeline(request, options = nil) ⇒ ::Google::Protobuf::Empty #cancel_training_pipeline(name: nil) ⇒ ::Google::Protobuf::Empty
Cancels a TrainingPipeline.
Starts asynchronous cancellation on the TrainingPipeline. The server
makes a best effort to cancel the pipeline, but success is not
guaranteed. Clients can use
PipelineService.GetTrainingPipeline
or other methods to check whether the cancellation succeeded or whether the
pipeline completed despite cancellation. On successful cancellation,
the TrainingPipeline is not deleted; instead it becomes a pipeline with
a
TrainingPipeline.error
value with a google.rpc.Status.code of 1,
corresponding to Code.CANCELLED
, and
TrainingPipeline.state
is set to CANCELLED
.
635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 635 def cancel_training_pipeline request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CancelTrainingPipelineRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.cancel_training_pipeline..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.cancel_training_pipeline.timeout, metadata: , retry_policy: @config.rpcs.cancel_training_pipeline.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.cancel_training_pipeline request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#configure {|config| ... } ⇒ Client::Configuration
Configure the PipelineService Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on configure.
See Configuration for a description of the configuration fields.
100 101 102 103 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 100 def configure yield @config if block_given? @config end |
#create_pipeline_job(request, options = nil) ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob #create_pipeline_job(parent: nil, pipeline_job: nil, pipeline_job_id: nil) ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob
Creates a PipelineJob. A PipelineJob will run immediately when created.
724 725 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 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 724 def create_pipeline_job request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CreatePipelineJobRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_pipeline_job..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_pipeline_job.timeout, metadata: , retry_policy: @config.rpcs.create_pipeline_job.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.create_pipeline_job request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_training_pipeline(request, options = nil) ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline #create_training_pipeline(parent: nil, training_pipeline: nil) ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline
Creates a TrainingPipeline. A created TrainingPipeline right away will be attempted to be run.
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 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 254 def create_training_pipeline request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CreateTrainingPipelineRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_training_pipeline..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_training_pipeline.timeout, metadata: , retry_policy: @config.rpcs.create_training_pipeline.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.create_training_pipeline request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_pipeline_job(request, options = nil) ⇒ ::Gapic::Operation #delete_pipeline_job(name: nil) ⇒ ::Gapic::Operation
Deletes a PipelineJob.
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 1071 1072 1073 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 1038 def delete_pipeline_job request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::DeletePipelineJobRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_pipeline_job..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_pipeline_job.timeout, metadata: , retry_policy: @config.rpcs.delete_pipeline_job.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.delete_pipeline_job request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_training_pipeline(request, options = nil) ⇒ ::Gapic::Operation #delete_training_pipeline(name: nil) ⇒ ::Gapic::Operation
Deletes a TrainingPipeline.
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 571 572 573 574 575 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 540 def delete_training_pipeline request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::DeleteTrainingPipelineRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_training_pipeline..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_training_pipeline.timeout, metadata: , retry_policy: @config.rpcs.delete_training_pipeline.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.delete_training_pipeline request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_pipeline_job(request, options = nil) ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob #get_pipeline_job(name: nil) ⇒ ::Google::Cloud::AIPlatform::V1::PipelineJob
Gets a PipelineJob.
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 839 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 805 def get_pipeline_job request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::GetPipelineJobRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_pipeline_job..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_pipeline_job.timeout, metadata: , retry_policy: @config.rpcs.get_pipeline_job.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.get_pipeline_job request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_training_pipeline(request, options = nil) ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline #get_training_pipeline(name: nil) ⇒ ::Google::Cloud::AIPlatform::V1::TrainingPipeline
Gets a TrainingPipeline.
335 336 337 338 339 340 341 342 343 344 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 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 335 def get_training_pipeline request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::GetTrainingPipelineRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_training_pipeline..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_training_pipeline.timeout, metadata: , retry_policy: @config.rpcs.get_training_pipeline.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.get_training_pipeline request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_pipeline_jobs(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::PipelineJob> #list_pipeline_jobs(parent: nil, filter: nil, page_size: nil, page_token: nil, order_by: nil, read_mask: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::PipelineJob>
Lists PipelineJobs in a Location.
949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 949 def list_pipeline_jobs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::ListPipelineJobsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_pipeline_jobs..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_pipeline_jobs.timeout, metadata: , retry_policy: @config.rpcs.list_pipeline_jobs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.list_pipeline_jobs request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @pipeline_service_stub, :list_pipeline_jobs, "pipeline_jobs", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_training_pipelines(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::TrainingPipeline> #list_training_pipelines(parent: nil, filter: nil, page_size: nil, page_token: nil, read_mask: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::TrainingPipeline>
Lists TrainingPipelines in a Location.
451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 451 def list_training_pipelines request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::ListTrainingPipelinesRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_training_pipelines..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_training_pipelines.timeout, metadata: , retry_policy: @config.rpcs.list_training_pipelines.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @pipeline_service_stub.list_training_pipelines request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @pipeline_service_stub, :list_training_pipelines, "training_pipelines", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#universe_domain ⇒ String
The effective universe domain
110 111 112 |
# File 'lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb', line 110 def universe_domain @pipeline_service_stub.universe_domain end |