google-cloud-ai_platform-v1 0.38.0 → 0.40.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (231) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/ai_platform/v1/bindings_override.rb +399 -0
  3. data/lib/google/cloud/ai_platform/v1/dataset_service/client.rb +39 -18
  4. data/lib/google/cloud/ai_platform/v1/dataset_service/operations.rb +13 -5
  5. data/lib/google/cloud/ai_platform/v1/dataset_service/rest/client.rb +2188 -0
  6. data/lib/google/cloud/ai_platform/v1/dataset_service/rest/operations.rb +3901 -0
  7. data/lib/google/cloud/ai_platform/v1/dataset_service/rest/service_stub.rb +1136 -0
  8. data/lib/google/cloud/ai_platform/v1/dataset_service/rest.rb +54 -0
  9. data/lib/google/cloud/ai_platform/v1/dataset_service.rb +6 -0
  10. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/client.rb +13 -5
  11. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/operations.rb +13 -5
  12. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest/client.rb +851 -0
  13. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest/operations.rb +3901 -0
  14. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest/service_stub.rb +365 -0
  15. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest.rb +54 -0
  16. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service.rb +6 -0
  17. data/lib/google/cloud/ai_platform/v1/endpoint_service/client.rb +21 -11
  18. data/lib/google/cloud/ai_platform/v1/endpoint_service/operations.rb +13 -5
  19. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest/client.rb +1215 -0
  20. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest/operations.rb +3901 -0
  21. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest/service_stub.rb +546 -0
  22. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest.rb +54 -0
  23. data/lib/google/cloud/ai_platform/v1/endpoint_service.rb +6 -0
  24. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/client.rb +29 -13
  25. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/operations.rb +13 -5
  26. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest/client.rb +1732 -0
  27. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest/operations.rb +3901 -0
  28. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest/service_stub.rb +841 -0
  29. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest.rb +55 -0
  30. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service.rb +6 -0
  31. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/client.rb +7 -2
  32. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/rest/client.rb +534 -0
  33. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/rest/service_stub.rb +189 -0
  34. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/rest.rb +53 -0
  35. data/lib/google/cloud/ai_platform/v1/feature_online_store_service.rb +6 -0
  36. data/lib/google/cloud/ai_platform/v1/feature_registry_service/client.rb +24 -11
  37. data/lib/google/cloud/ai_platform/v1/feature_registry_service/operations.rb +13 -5
  38. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest/client.rb +1450 -0
  39. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest/operations.rb +3901 -0
  40. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest/service_stub.rb +663 -0
  41. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest.rb +55 -0
  42. data/lib/google/cloud/ai_platform/v1/feature_registry_service.rb +6 -0
  43. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/client.rb +9 -3
  44. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/rest/client.rb +645 -0
  45. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/rest/service_stub.rb +244 -0
  46. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/rest.rb +53 -0
  47. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service.rb +6 -0
  48. data/lib/google/cloud/ai_platform/v1/featurestore_service/client.rb +45 -21
  49. data/lib/google/cloud/ai_platform/v1/featurestore_service/operations.rb +13 -5
  50. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest/client.rb +2765 -0
  51. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest/operations.rb +3901 -0
  52. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest/service_stub.rb +1319 -0
  53. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest.rb +54 -0
  54. data/lib/google/cloud/ai_platform/v1/featurestore_service.rb +6 -0
  55. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/client.rb +765 -0
  56. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/credentials.rb +47 -0
  57. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/paths.rb +154 -0
  58. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/rest/client.rb +720 -0
  59. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/rest/service_stub.rb +307 -0
  60. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/rest.rb +53 -0
  61. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service.rb +55 -0
  62. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/client.rb +19 -8
  63. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/operations.rb +13 -5
  64. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest/client.rb +1151 -0
  65. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest/operations.rb +3901 -0
  66. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest/service_stub.rb +546 -0
  67. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest.rb +54 -0
  68. data/lib/google/cloud/ai_platform/v1/index_endpoint_service.rb +6 -0
  69. data/lib/google/cloud/ai_platform/v1/index_service/client.rb +17 -7
  70. data/lib/google/cloud/ai_platform/v1/index_service/operations.rb +13 -5
  71. data/lib/google/cloud/ai_platform/v1/index_service/rest/client.rb +1034 -0
  72. data/lib/google/cloud/ai_platform/v1/index_service/rest/operations.rb +3901 -0
  73. data/lib/google/cloud/ai_platform/v1/index_service/rest/service_stub.rb +486 -0
  74. data/lib/google/cloud/ai_platform/v1/index_service/rest.rb +54 -0
  75. data/lib/google/cloud/ai_platform/v1/index_service.rb +6 -0
  76. data/lib/google/cloud/ai_platform/v1/job_service/client.rb +73 -35
  77. data/lib/google/cloud/ai_platform/v1/job_service/operations.rb +13 -5
  78. data/lib/google/cloud/ai_platform/v1/job_service/paths.rb +19 -0
  79. data/lib/google/cloud/ai_platform/v1/job_service/rest/client.rb +3841 -0
  80. data/lib/google/cloud/ai_platform/v1/job_service/rest/operations.rb +3901 -0
  81. data/lib/google/cloud/ai_platform/v1/job_service/rest/service_stub.rb +2149 -0
  82. data/lib/google/cloud/ai_platform/v1/job_service/rest.rb +54 -0
  83. data/lib/google/cloud/ai_platform/v1/job_service.rb +6 -0
  84. data/lib/google/cloud/ai_platform/v1/llm_utility_service/client.rb +7 -2
  85. data/lib/google/cloud/ai_platform/v1/llm_utility_service/rest/client.rb +533 -0
  86. data/lib/google/cloud/ai_platform/v1/llm_utility_service/rest/service_stub.rb +205 -0
  87. data/lib/google/cloud/ai_platform/v1/llm_utility_service/rest.rb +53 -0
  88. data/lib/google/cloud/ai_platform/v1/llm_utility_service.rb +6 -0
  89. data/lib/google/cloud/ai_platform/v1/match_service/client.rb +7 -2
  90. data/lib/google/cloud/ai_platform/v1/match_service/rest/client.rb +541 -0
  91. data/lib/google/cloud/ai_platform/v1/match_service/rest/service_stub.rb +189 -0
  92. data/lib/google/cloud/ai_platform/v1/match_service/rest.rb +54 -0
  93. data/lib/google/cloud/ai_platform/v1/match_service.rb +6 -0
  94. data/lib/google/cloud/ai_platform/v1/metadata_service/client.rb +67 -32
  95. data/lib/google/cloud/ai_platform/v1/metadata_service/operations.rb +13 -5
  96. data/lib/google/cloud/ai_platform/v1/metadata_service/rest/client.rb +3634 -0
  97. data/lib/google/cloud/ai_platform/v1/metadata_service/rest/operations.rb +3901 -0
  98. data/lib/google/cloud/ai_platform/v1/metadata_service/rest/service_stub.rb +1972 -0
  99. data/lib/google/cloud/ai_platform/v1/metadata_service/rest.rb +54 -0
  100. data/lib/google/cloud/ai_platform/v1/metadata_service.rb +6 -0
  101. data/lib/google/cloud/ai_platform/v1/migration_service/client.rb +7 -2
  102. data/lib/google/cloud/ai_platform/v1/migration_service/operations.rb +13 -5
  103. data/lib/google/cloud/ai_platform/v1/migration_service/rest/client.rb +574 -0
  104. data/lib/google/cloud/ai_platform/v1/migration_service/rest/operations.rb +3901 -0
  105. data/lib/google/cloud/ai_platform/v1/migration_service/rest/service_stub.rb +189 -0
  106. data/lib/google/cloud/ai_platform/v1/migration_service/rest.rb +55 -0
  107. data/lib/google/cloud/ai_platform/v1/migration_service.rb +6 -0
  108. data/lib/google/cloud/ai_platform/v1/model_garden_service/client.rb +5 -1
  109. data/lib/google/cloud/ai_platform/v1/model_garden_service/rest/client.rb +438 -0
  110. data/lib/google/cloud/ai_platform/v1/model_garden_service/rest/service_stub.rb +128 -0
  111. data/lib/google/cloud/ai_platform/v1/model_garden_service/rest.rb +53 -0
  112. data/lib/google/cloud/ai_platform/v1/model_garden_service.rb +6 -0
  113. data/lib/google/cloud/ai_platform/v1/model_service/client.rb +39 -18
  114. data/lib/google/cloud/ai_platform/v1/model_service/operations.rb +13 -5
  115. data/lib/google/cloud/ai_platform/v1/model_service/rest/client.rb +2213 -0
  116. data/lib/google/cloud/ai_platform/v1/model_service/rest/operations.rb +3901 -0
  117. data/lib/google/cloud/ai_platform/v1/model_service/rest/service_stub.rb +1140 -0
  118. data/lib/google/cloud/ai_platform/v1/model_service/rest.rb +54 -0
  119. data/lib/google/cloud/ai_platform/v1/model_service.rb +6 -0
  120. data/lib/google/cloud/ai_platform/v1/notebook_service/client.rb +1497 -0
  121. data/lib/google/cloud/ai_platform/v1/notebook_service/credentials.rb +47 -0
  122. data/lib/google/cloud/ai_platform/v1/notebook_service/operations.rb +817 -0
  123. data/lib/google/cloud/ai_platform/v1/notebook_service/paths.rb +124 -0
  124. data/lib/google/cloud/ai_platform/v1/notebook_service/rest/client.rb +1410 -0
  125. data/lib/google/cloud/ai_platform/v1/notebook_service/rest/operations.rb +3901 -0
  126. data/lib/google/cloud/ai_platform/v1/notebook_service/rest/service_stub.rb +663 -0
  127. data/lib/google/cloud/ai_platform/v1/notebook_service/rest.rb +54 -0
  128. data/lib/google/cloud/ai_platform/v1/notebook_service.rb +56 -0
  129. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/client.rb +1001 -0
  130. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/credentials.rb +47 -0
  131. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/operations.rb +817 -0
  132. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/paths.rb +86 -0
  133. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest/client.rb +942 -0
  134. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest/operations.rb +3901 -0
  135. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest/service_stub.rb +426 -0
  136. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest.rb +54 -0
  137. data/lib/google/cloud/ai_platform/v1/persistent_resource_service.rb +56 -0
  138. data/lib/google/cloud/ai_platform/v1/pipeline_service/client.rb +27 -12
  139. data/lib/google/cloud/ai_platform/v1/pipeline_service/operations.rb +13 -5
  140. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb +1600 -0
  141. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest/operations.rb +3901 -0
  142. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest/service_stub.rb +783 -0
  143. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest.rb +56 -0
  144. data/lib/google/cloud/ai_platform/v1/pipeline_service.rb +6 -0
  145. data/lib/google/cloud/ai_platform/v1/prediction_service/client.rb +39 -15
  146. data/lib/google/cloud/ai_platform/v1/prediction_service/rest/client.rb +1297 -0
  147. data/lib/google/cloud/ai_platform/v1/prediction_service/rest/service_stub.rb +642 -0
  148. data/lib/google/cloud/ai_platform/v1/prediction_service/rest.rb +53 -0
  149. data/lib/google/cloud/ai_platform/v1/prediction_service.rb +6 -0
  150. data/lib/google/cloud/ai_platform/v1/rest.rb +63 -0
  151. data/lib/google/cloud/ai_platform/v1/schedule_service/client.rb +17 -7
  152. data/lib/google/cloud/ai_platform/v1/schedule_service/operations.rb +13 -5
  153. data/lib/google/cloud/ai_platform/v1/schedule_service/rest/client.rb +1076 -0
  154. data/lib/google/cloud/ai_platform/v1/schedule_service/rest/operations.rb +3901 -0
  155. data/lib/google/cloud/ai_platform/v1/schedule_service/rest/service_stub.rb +486 -0
  156. data/lib/google/cloud/ai_platform/v1/schedule_service/rest.rb +55 -0
  157. data/lib/google/cloud/ai_platform/v1/schedule_service.rb +6 -0
  158. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/client.rb +13 -5
  159. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/operations.rb +13 -5
  160. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest/client.rb +847 -0
  161. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest/operations.rb +3901 -0
  162. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest/service_stub.rb +366 -0
  163. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest.rb +59 -0
  164. data/lib/google/cloud/ai_platform/v1/specialist_pool_service.rb +6 -0
  165. data/lib/google/cloud/ai_platform/v1/tensorboard_service/client.rb +63 -30
  166. data/lib/google/cloud/ai_platform/v1/tensorboard_service/operations.rb +13 -5
  167. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest/client.rb +3274 -0
  168. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest/operations.rb +3901 -0
  169. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest/service_stub.rb +1847 -0
  170. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest.rb +54 -0
  171. data/lib/google/cloud/ai_platform/v1/tensorboard_service.rb +6 -0
  172. data/lib/google/cloud/ai_platform/v1/version.rb +1 -1
  173. data/lib/google/cloud/ai_platform/v1/vizier_service/client.rb +33 -15
  174. data/lib/google/cloud/ai_platform/v1/vizier_service/operations.rb +13 -5
  175. data/lib/google/cloud/ai_platform/v1/vizier_service/rest/client.rb +1788 -0
  176. data/lib/google/cloud/ai_platform/v1/vizier_service/rest/operations.rb +3901 -0
  177. data/lib/google/cloud/ai_platform/v1/vizier_service/rest/service_stub.rb +963 -0
  178. data/lib/google/cloud/ai_platform/v1/vizier_service/rest.rb +58 -0
  179. data/lib/google/cloud/ai_platform/v1/vizier_service.rb +6 -0
  180. data/lib/google/cloud/ai_platform/v1.rb +9 -1
  181. data/lib/google/cloud/aiplatform/v1/accelerator_type_pb.rb +1 -1
  182. data/lib/google/cloud/aiplatform/v1/content_pb.rb +3 -1
  183. data/lib/google/cloud/aiplatform/v1/custom_job_pb.rb +1 -1
  184. data/lib/google/cloud/aiplatform/v1/endpoint_pb.rb +3 -1
  185. data/lib/google/cloud/aiplatform/v1/feature_online_store_pb.rb +3 -1
  186. data/lib/google/cloud/aiplatform/v1/feature_online_store_service_pb.rb +1 -1
  187. data/lib/google/cloud/aiplatform/v1/feature_view_pb.rb +5 -1
  188. data/lib/google/cloud/aiplatform/v1/genai_tuning_service_pb.rb +54 -0
  189. data/lib/google/cloud/aiplatform/v1/genai_tuning_service_services_pb.rb +63 -0
  190. data/lib/google/cloud/aiplatform/v1/index_service_pb.rb +1 -1
  191. data/lib/google/cloud/aiplatform/v1/machine_resources_pb.rb +2 -1
  192. data/lib/google/cloud/aiplatform/v1/network_spec_pb.rb +44 -0
  193. data/lib/google/cloud/aiplatform/v1/notebook_euc_config_pb.rb +44 -0
  194. data/lib/google/cloud/aiplatform/v1/notebook_idle_shutdown_config_pb.rb +46 -0
  195. data/lib/google/cloud/aiplatform/v1/notebook_runtime_pb.rb +61 -0
  196. data/lib/google/cloud/aiplatform/v1/notebook_runtime_template_ref_pb.rb +45 -0
  197. data/lib/google/cloud/aiplatform/v1/notebook_service_pb.rb +72 -0
  198. data/lib/google/cloud/aiplatform/v1/notebook_service_services_pb.rb +64 -0
  199. data/lib/google/cloud/aiplatform/v1/openapi_pb.rb +1 -1
  200. data/lib/google/cloud/aiplatform/v1/persistent_resource_pb.rb +60 -0
  201. data/lib/google/cloud/aiplatform/v1/persistent_resource_service_pb.rb +64 -0
  202. data/lib/google/cloud/aiplatform/v1/persistent_resource_service_services_pb.rb +55 -0
  203. data/lib/google/cloud/aiplatform/v1/prediction_service_pb.rb +1 -1
  204. data/lib/google/cloud/aiplatform/v1/publisher_model_pb.rb +1 -1
  205. data/lib/google/cloud/aiplatform/v1/tuning_job_pb.rb +60 -0
  206. data/proto_docs/google/cloud/aiplatform/v1/accelerator_type.rb +3 -0
  207. data/proto_docs/google/cloud/aiplatform/v1/content.rb +52 -3
  208. data/proto_docs/google/cloud/aiplatform/v1/custom_job.rb +9 -0
  209. data/proto_docs/google/cloud/aiplatform/v1/endpoint.rb +14 -0
  210. data/proto_docs/google/cloud/aiplatform/v1/endpoint_service.rb +2 -3
  211. data/proto_docs/google/cloud/aiplatform/v1/feature_online_store.rb +29 -0
  212. data/proto_docs/google/cloud/aiplatform/v1/feature_online_store_service.rb +5 -0
  213. data/proto_docs/google/cloud/aiplatform/v1/feature_registry_service.rb +1 -1
  214. data/proto_docs/google/cloud/aiplatform/v1/feature_view.rb +86 -0
  215. data/proto_docs/google/cloud/aiplatform/v1/genai_tuning_service.rb +100 -0
  216. data/proto_docs/google/cloud/aiplatform/v1/index_service.rb +3 -0
  217. data/proto_docs/google/cloud/aiplatform/v1/machine_resources.rb +17 -0
  218. data/proto_docs/google/cloud/aiplatform/v1/network_spec.rb +44 -0
  219. data/proto_docs/google/cloud/aiplatform/v1/notebook_euc_config.rb +46 -0
  220. data/proto_docs/google/cloud/aiplatform/v1/notebook_idle_shutdown_config.rb +41 -0
  221. data/proto_docs/google/cloud/aiplatform/v1/notebook_runtime.rb +263 -0
  222. data/proto_docs/google/cloud/aiplatform/v1/notebook_runtime_template_ref.rb +35 -0
  223. data/proto_docs/google/cloud/aiplatform/v1/notebook_service.rb +371 -0
  224. data/proto_docs/google/cloud/aiplatform/v1/openapi.rb +43 -4
  225. data/proto_docs/google/cloud/aiplatform/v1/persistent_resource.rb +248 -0
  226. data/proto_docs/google/cloud/aiplatform/v1/persistent_resource_service.rb +170 -0
  227. data/proto_docs/google/cloud/aiplatform/v1/prediction_service.rb +12 -0
  228. data/proto_docs/google/cloud/aiplatform/v1/publisher_model.rb +4 -0
  229. data/proto_docs/google/cloud/aiplatform/v1/tool.rb +7 -5
  230. data/proto_docs/google/cloud/aiplatform/v1/tuning_job.rb +262 -0
  231. metadata +138 -2
@@ -0,0 +1,1497 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2024 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "google/cloud/errors"
20
+ require "google/cloud/aiplatform/v1/notebook_service_pb"
21
+ require "google/cloud/location"
22
+ require "google/iam/v1"
23
+
24
+ module Google
25
+ module Cloud
26
+ module AIPlatform
27
+ module V1
28
+ module NotebookService
29
+ ##
30
+ # Client for the NotebookService service.
31
+ #
32
+ # The interface for Vertex Notebook service (a.k.a. Colab on Workbench).
33
+ #
34
+ class Client
35
+ # @private
36
+ API_VERSION = ""
37
+
38
+ # @private
39
+ DEFAULT_ENDPOINT_TEMPLATE = "aiplatform.$UNIVERSE_DOMAIN$"
40
+
41
+ include Paths
42
+
43
+ # @private
44
+ attr_reader :notebook_service_stub
45
+
46
+ ##
47
+ # Configure the NotebookService Client class.
48
+ #
49
+ # See {::Google::Cloud::AIPlatform::V1::NotebookService::Client::Configuration}
50
+ # for a description of the configuration fields.
51
+ #
52
+ # @example
53
+ #
54
+ # # Modify the configuration for all NotebookService clients
55
+ # ::Google::Cloud::AIPlatform::V1::NotebookService::Client.configure do |config|
56
+ # config.timeout = 10.0
57
+ # end
58
+ #
59
+ # @yield [config] Configure the Client client.
60
+ # @yieldparam config [Client::Configuration]
61
+ #
62
+ # @return [Client::Configuration]
63
+ #
64
+ def self.configure
65
+ @configure ||= begin
66
+ namespace = ["Google", "Cloud", "AIPlatform", "V1"]
67
+ parent_config = while namespace.any?
68
+ parent_name = namespace.join "::"
69
+ parent_const = const_get parent_name
70
+ break parent_const.configure if parent_const.respond_to? :configure
71
+ namespace.pop
72
+ end
73
+ default_config = Client::Configuration.new parent_config
74
+
75
+ default_config
76
+ end
77
+ yield @configure if block_given?
78
+ @configure
79
+ end
80
+
81
+ ##
82
+ # Configure the NotebookService Client instance.
83
+ #
84
+ # The configuration is set to the derived mode, meaning that values can be changed,
85
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
86
+ # should be made on {Client.configure}.
87
+ #
88
+ # See {::Google::Cloud::AIPlatform::V1::NotebookService::Client::Configuration}
89
+ # for a description of the configuration fields.
90
+ #
91
+ # @yield [config] Configure the Client client.
92
+ # @yieldparam config [Client::Configuration]
93
+ #
94
+ # @return [Client::Configuration]
95
+ #
96
+ def configure
97
+ yield @config if block_given?
98
+ @config
99
+ end
100
+
101
+ ##
102
+ # The effective universe domain
103
+ #
104
+ # @return [String]
105
+ #
106
+ def universe_domain
107
+ @notebook_service_stub.universe_domain
108
+ end
109
+
110
+ ##
111
+ # Create a new NotebookService client object.
112
+ #
113
+ # @example
114
+ #
115
+ # # Create a client using the default configuration
116
+ # client = ::Google::Cloud::AIPlatform::V1::NotebookService::Client.new
117
+ #
118
+ # # Create a client using a custom configuration
119
+ # client = ::Google::Cloud::AIPlatform::V1::NotebookService::Client.new do |config|
120
+ # config.timeout = 10.0
121
+ # end
122
+ #
123
+ # @yield [config] Configure the NotebookService client.
124
+ # @yieldparam config [Client::Configuration]
125
+ #
126
+ def initialize
127
+ # These require statements are intentionally placed here to initialize
128
+ # the gRPC module only when it's required.
129
+ # See https://github.com/googleapis/toolkit/issues/446
130
+ require "gapic/grpc"
131
+ require "google/cloud/aiplatform/v1/notebook_service_services_pb"
132
+
133
+ # Create the configuration object
134
+ @config = Configuration.new Client.configure
135
+
136
+ # Yield the configuration if needed
137
+ yield @config if block_given?
138
+
139
+ # Create credentials
140
+ credentials = @config.credentials
141
+ # Use self-signed JWT if the endpoint is unchanged from default,
142
+ # but only if the default endpoint does not have a region prefix.
143
+ enable_self_signed_jwt = @config.endpoint.nil? ||
144
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
145
+ !@config.endpoint.split(".").first.include?("-"))
146
+ credentials ||= Credentials.default scope: @config.scope,
147
+ enable_self_signed_jwt: enable_self_signed_jwt
148
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
149
+ credentials = Credentials.new credentials, scope: @config.scope
150
+ end
151
+ @quota_project_id = @config.quota_project
152
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
153
+
154
+ @operations_client = Operations.new do |config|
155
+ config.credentials = credentials
156
+ config.quota_project = @quota_project_id
157
+ config.endpoint = @config.endpoint
158
+ config.universe_domain = @config.universe_domain
159
+ end
160
+
161
+ @notebook_service_stub = ::Gapic::ServiceStub.new(
162
+ ::Google::Cloud::AIPlatform::V1::NotebookService::Stub,
163
+ credentials: credentials,
164
+ endpoint: @config.endpoint,
165
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
166
+ universe_domain: @config.universe_domain,
167
+ channel_args: @config.channel_args,
168
+ interceptors: @config.interceptors,
169
+ channel_pool_config: @config.channel_pool
170
+ )
171
+
172
+ @location_client = Google::Cloud::Location::Locations::Client.new do |config|
173
+ config.credentials = credentials
174
+ config.quota_project = @quota_project_id
175
+ config.endpoint = @notebook_service_stub.endpoint
176
+ config.universe_domain = @notebook_service_stub.universe_domain
177
+ end
178
+
179
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Client.new do |config|
180
+ config.credentials = credentials
181
+ config.quota_project = @quota_project_id
182
+ config.endpoint = @notebook_service_stub.endpoint
183
+ config.universe_domain = @notebook_service_stub.universe_domain
184
+ end
185
+ end
186
+
187
+ ##
188
+ # Get the associated client for long-running operations.
189
+ #
190
+ # @return [::Google::Cloud::AIPlatform::V1::NotebookService::Operations]
191
+ #
192
+ attr_reader :operations_client
193
+
194
+ ##
195
+ # Get the associated client for mix-in of the Locations.
196
+ #
197
+ # @return [Google::Cloud::Location::Locations::Client]
198
+ #
199
+ attr_reader :location_client
200
+
201
+ ##
202
+ # Get the associated client for mix-in of the IAMPolicy.
203
+ #
204
+ # @return [Google::Iam::V1::IAMPolicy::Client]
205
+ #
206
+ attr_reader :iam_policy_client
207
+
208
+ # Service calls
209
+
210
+ ##
211
+ # Creates a NotebookRuntimeTemplate.
212
+ #
213
+ # @overload create_notebook_runtime_template(request, options = nil)
214
+ # Pass arguments to `create_notebook_runtime_template` via a request object, either of type
215
+ # {::Google::Cloud::AIPlatform::V1::CreateNotebookRuntimeTemplateRequest} or an equivalent Hash.
216
+ #
217
+ # @param request [::Google::Cloud::AIPlatform::V1::CreateNotebookRuntimeTemplateRequest, ::Hash]
218
+ # A request object representing the call parameters. Required. To specify no
219
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
220
+ # @param options [::Gapic::CallOptions, ::Hash]
221
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
222
+ #
223
+ # @overload create_notebook_runtime_template(parent: nil, notebook_runtime_template: nil, notebook_runtime_template_id: nil)
224
+ # Pass arguments to `create_notebook_runtime_template` via keyword arguments. Note that at
225
+ # least one keyword argument is required. To specify no parameters, or to keep all
226
+ # the default parameter values, pass an empty Hash as a request object (see above).
227
+ #
228
+ # @param parent [::String]
229
+ # Required. The resource name of the Location to create the
230
+ # NotebookRuntimeTemplate. Format: `projects/{project}/locations/{location}`
231
+ # @param notebook_runtime_template [::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate, ::Hash]
232
+ # Required. The NotebookRuntimeTemplate to create.
233
+ # @param notebook_runtime_template_id [::String]
234
+ # Optional. User specified ID for the notebook runtime template.
235
+ #
236
+ # @yield [response, operation] Access the result along with the RPC operation
237
+ # @yieldparam response [::Gapic::Operation]
238
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
239
+ #
240
+ # @return [::Gapic::Operation]
241
+ #
242
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
243
+ #
244
+ # @example Basic example
245
+ # require "google/cloud/ai_platform/v1"
246
+ #
247
+ # # Create a client object. The client can be reused for multiple calls.
248
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
249
+ #
250
+ # # Create a request. To set request fields, pass in keyword arguments.
251
+ # request = Google::Cloud::AIPlatform::V1::CreateNotebookRuntimeTemplateRequest.new
252
+ #
253
+ # # Call the create_notebook_runtime_template method.
254
+ # result = client.create_notebook_runtime_template request
255
+ #
256
+ # # The returned object is of type Gapic::Operation. You can use it to
257
+ # # check the status of an operation, cancel it, or wait for results.
258
+ # # Here is how to wait for a response.
259
+ # result.wait_until_done! timeout: 60
260
+ # if result.response?
261
+ # p result.response
262
+ # else
263
+ # puts "No response received."
264
+ # end
265
+ #
266
+ def create_notebook_runtime_template request, options = nil
267
+ raise ::ArgumentError, "request must be provided" if request.nil?
268
+
269
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CreateNotebookRuntimeTemplateRequest
270
+
271
+ # Converts hash and nil to an options object
272
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
273
+
274
+ # Customize the options with defaults
275
+ metadata = @config.rpcs.create_notebook_runtime_template.metadata.to_h
276
+
277
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
278
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
279
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
280
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
281
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
282
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
283
+
284
+ header_params = {}
285
+ if request.parent
286
+ header_params["parent"] = request.parent
287
+ end
288
+
289
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
290
+ metadata[:"x-goog-request-params"] ||= request_params_header
291
+
292
+ options.apply_defaults timeout: @config.rpcs.create_notebook_runtime_template.timeout,
293
+ metadata: metadata,
294
+ retry_policy: @config.rpcs.create_notebook_runtime_template.retry_policy
295
+
296
+ options.apply_defaults timeout: @config.timeout,
297
+ metadata: @config.metadata,
298
+ retry_policy: @config.retry_policy
299
+
300
+ @notebook_service_stub.call_rpc :create_notebook_runtime_template, request, options: options do |response, operation|
301
+ response = ::Gapic::Operation.new response, @operations_client, options: options
302
+ yield response, operation if block_given?
303
+ return response
304
+ end
305
+ rescue ::GRPC::BadStatus => e
306
+ raise ::Google::Cloud::Error.from_error(e)
307
+ end
308
+
309
+ ##
310
+ # Gets a NotebookRuntimeTemplate.
311
+ #
312
+ # @overload get_notebook_runtime_template(request, options = nil)
313
+ # Pass arguments to `get_notebook_runtime_template` via a request object, either of type
314
+ # {::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeTemplateRequest} or an equivalent Hash.
315
+ #
316
+ # @param request [::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeTemplateRequest, ::Hash]
317
+ # A request object representing the call parameters. Required. To specify no
318
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
319
+ # @param options [::Gapic::CallOptions, ::Hash]
320
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
321
+ #
322
+ # @overload get_notebook_runtime_template(name: nil)
323
+ # Pass arguments to `get_notebook_runtime_template` via keyword arguments. Note that at
324
+ # least one keyword argument is required. To specify no parameters, or to keep all
325
+ # the default parameter values, pass an empty Hash as a request object (see above).
326
+ #
327
+ # @param name [::String]
328
+ # Required. The name of the NotebookRuntimeTemplate resource.
329
+ # Format:
330
+ # `projects/{project}/locations/{location}/notebookRuntimeTemplates/{notebook_runtime_template}`
331
+ #
332
+ # @yield [response, operation] Access the result along with the RPC operation
333
+ # @yieldparam response [::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate]
334
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
335
+ #
336
+ # @return [::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate]
337
+ #
338
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
339
+ #
340
+ # @example Basic example
341
+ # require "google/cloud/ai_platform/v1"
342
+ #
343
+ # # Create a client object. The client can be reused for multiple calls.
344
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
345
+ #
346
+ # # Create a request. To set request fields, pass in keyword arguments.
347
+ # request = Google::Cloud::AIPlatform::V1::GetNotebookRuntimeTemplateRequest.new
348
+ #
349
+ # # Call the get_notebook_runtime_template method.
350
+ # result = client.get_notebook_runtime_template request
351
+ #
352
+ # # The returned object is of type Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate.
353
+ # p result
354
+ #
355
+ def get_notebook_runtime_template request, options = nil
356
+ raise ::ArgumentError, "request must be provided" if request.nil?
357
+
358
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeTemplateRequest
359
+
360
+ # Converts hash and nil to an options object
361
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
362
+
363
+ # Customize the options with defaults
364
+ metadata = @config.rpcs.get_notebook_runtime_template.metadata.to_h
365
+
366
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
367
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
368
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
369
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
370
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
371
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
372
+
373
+ header_params = {}
374
+ if request.name
375
+ header_params["name"] = request.name
376
+ end
377
+
378
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
379
+ metadata[:"x-goog-request-params"] ||= request_params_header
380
+
381
+ options.apply_defaults timeout: @config.rpcs.get_notebook_runtime_template.timeout,
382
+ metadata: metadata,
383
+ retry_policy: @config.rpcs.get_notebook_runtime_template.retry_policy
384
+
385
+ options.apply_defaults timeout: @config.timeout,
386
+ metadata: @config.metadata,
387
+ retry_policy: @config.retry_policy
388
+
389
+ @notebook_service_stub.call_rpc :get_notebook_runtime_template, request, options: options do |response, operation|
390
+ yield response, operation if block_given?
391
+ return response
392
+ end
393
+ rescue ::GRPC::BadStatus => e
394
+ raise ::Google::Cloud::Error.from_error(e)
395
+ end
396
+
397
+ ##
398
+ # Lists NotebookRuntimeTemplates in a Location.
399
+ #
400
+ # @overload list_notebook_runtime_templates(request, options = nil)
401
+ # Pass arguments to `list_notebook_runtime_templates` via a request object, either of type
402
+ # {::Google::Cloud::AIPlatform::V1::ListNotebookRuntimeTemplatesRequest} or an equivalent Hash.
403
+ #
404
+ # @param request [::Google::Cloud::AIPlatform::V1::ListNotebookRuntimeTemplatesRequest, ::Hash]
405
+ # A request object representing the call parameters. Required. To specify no
406
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
407
+ # @param options [::Gapic::CallOptions, ::Hash]
408
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
409
+ #
410
+ # @overload list_notebook_runtime_templates(parent: nil, filter: nil, page_size: nil, page_token: nil, read_mask: nil, order_by: nil)
411
+ # Pass arguments to `list_notebook_runtime_templates` via keyword arguments. Note that at
412
+ # least one keyword argument is required. To specify no parameters, or to keep all
413
+ # the default parameter values, pass an empty Hash as a request object (see above).
414
+ #
415
+ # @param parent [::String]
416
+ # Required. The resource name of the Location from which to list the
417
+ # NotebookRuntimeTemplates.
418
+ # Format: `projects/{project}/locations/{location}`
419
+ # @param filter [::String]
420
+ # Optional. An expression for filtering the results of the request. For field
421
+ # names both snake_case and camelCase are supported.
422
+ #
423
+ # * `notebookRuntimeTemplate` supports = and !=. `notebookRuntimeTemplate`
424
+ # represents the NotebookRuntimeTemplate ID,
425
+ # i.e. the last segment of the NotebookRuntimeTemplate's [resource name]
426
+ # [google.cloud.aiplatform.v1.NotebookRuntimeTemplate.name].
427
+ # * `display_name` supports = and !=
428
+ # * `labels` supports general map functions that is:
429
+ # * `labels.key=value` - key:value equality
430
+ # * `labels.key:* or labels:key - key existence
431
+ # * A key including a space must be quoted. `labels."a key"`.
432
+ # * `notebookRuntimeType` supports = and !=. notebookRuntimeType enum:
433
+ # [USER_DEFINED, ONE_CLICK].
434
+ #
435
+ # Some examples:
436
+ #
437
+ # * `notebookRuntimeTemplate=notebookRuntimeTemplate123`
438
+ # * `displayName="myDisplayName"`
439
+ # * `labels.myKey="myValue"`
440
+ # * `notebookRuntimeType=USER_DEFINED`
441
+ # @param page_size [::Integer]
442
+ # Optional. The standard list page size.
443
+ # @param page_token [::String]
444
+ # Optional. The standard list page token.
445
+ # Typically obtained via
446
+ # {::Google::Cloud::AIPlatform::V1::ListNotebookRuntimeTemplatesResponse#next_page_token ListNotebookRuntimeTemplatesResponse.next_page_token}
447
+ # of the previous
448
+ # {::Google::Cloud::AIPlatform::V1::NotebookService::Client#list_notebook_runtime_templates NotebookService.ListNotebookRuntimeTemplates}
449
+ # call.
450
+ # @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
451
+ # Optional. Mask specifying which fields to read.
452
+ # @param order_by [::String]
453
+ # Optional. A comma-separated list of fields to order by, sorted in ascending
454
+ # order. Use "desc" after a field name for descending. Supported fields:
455
+ #
456
+ # * `display_name`
457
+ # * `create_time`
458
+ # * `update_time`
459
+ #
460
+ # Example: `display_name, create_time desc`.
461
+ #
462
+ # @yield [response, operation] Access the result along with the RPC operation
463
+ # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate>]
464
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
465
+ #
466
+ # @return [::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate>]
467
+ #
468
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
469
+ #
470
+ # @example Basic example
471
+ # require "google/cloud/ai_platform/v1"
472
+ #
473
+ # # Create a client object. The client can be reused for multiple calls.
474
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
475
+ #
476
+ # # Create a request. To set request fields, pass in keyword arguments.
477
+ # request = Google::Cloud::AIPlatform::V1::ListNotebookRuntimeTemplatesRequest.new
478
+ #
479
+ # # Call the list_notebook_runtime_templates method.
480
+ # result = client.list_notebook_runtime_templates request
481
+ #
482
+ # # The returned object is of type Gapic::PagedEnumerable. You can iterate
483
+ # # over elements, and API calls will be issued to fetch pages as needed.
484
+ # result.each do |item|
485
+ # # Each element is of type ::Google::Cloud::AIPlatform::V1::NotebookRuntimeTemplate.
486
+ # p item
487
+ # end
488
+ #
489
+ def list_notebook_runtime_templates request, options = nil
490
+ raise ::ArgumentError, "request must be provided" if request.nil?
491
+
492
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::ListNotebookRuntimeTemplatesRequest
493
+
494
+ # Converts hash and nil to an options object
495
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
496
+
497
+ # Customize the options with defaults
498
+ metadata = @config.rpcs.list_notebook_runtime_templates.metadata.to_h
499
+
500
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
501
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
502
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
503
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
504
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
505
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
506
+
507
+ header_params = {}
508
+ if request.parent
509
+ header_params["parent"] = request.parent
510
+ end
511
+
512
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
513
+ metadata[:"x-goog-request-params"] ||= request_params_header
514
+
515
+ options.apply_defaults timeout: @config.rpcs.list_notebook_runtime_templates.timeout,
516
+ metadata: metadata,
517
+ retry_policy: @config.rpcs.list_notebook_runtime_templates.retry_policy
518
+
519
+ options.apply_defaults timeout: @config.timeout,
520
+ metadata: @config.metadata,
521
+ retry_policy: @config.retry_policy
522
+
523
+ @notebook_service_stub.call_rpc :list_notebook_runtime_templates, request, options: options do |response, operation|
524
+ response = ::Gapic::PagedEnumerable.new @notebook_service_stub, :list_notebook_runtime_templates, request, response, operation, options
525
+ yield response, operation if block_given?
526
+ return response
527
+ end
528
+ rescue ::GRPC::BadStatus => e
529
+ raise ::Google::Cloud::Error.from_error(e)
530
+ end
531
+
532
+ ##
533
+ # Deletes a NotebookRuntimeTemplate.
534
+ #
535
+ # @overload delete_notebook_runtime_template(request, options = nil)
536
+ # Pass arguments to `delete_notebook_runtime_template` via a request object, either of type
537
+ # {::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeTemplateRequest} or an equivalent Hash.
538
+ #
539
+ # @param request [::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeTemplateRequest, ::Hash]
540
+ # A request object representing the call parameters. Required. To specify no
541
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
542
+ # @param options [::Gapic::CallOptions, ::Hash]
543
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
544
+ #
545
+ # @overload delete_notebook_runtime_template(name: nil)
546
+ # Pass arguments to `delete_notebook_runtime_template` via keyword arguments. Note that at
547
+ # least one keyword argument is required. To specify no parameters, or to keep all
548
+ # the default parameter values, pass an empty Hash as a request object (see above).
549
+ #
550
+ # @param name [::String]
551
+ # Required. The name of the NotebookRuntimeTemplate resource to be deleted.
552
+ # Format:
553
+ # `projects/{project}/locations/{location}/notebookRuntimeTemplates/{notebook_runtime_template}`
554
+ #
555
+ # @yield [response, operation] Access the result along with the RPC operation
556
+ # @yieldparam response [::Gapic::Operation]
557
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
558
+ #
559
+ # @return [::Gapic::Operation]
560
+ #
561
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
562
+ #
563
+ # @example Basic example
564
+ # require "google/cloud/ai_platform/v1"
565
+ #
566
+ # # Create a client object. The client can be reused for multiple calls.
567
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
568
+ #
569
+ # # Create a request. To set request fields, pass in keyword arguments.
570
+ # request = Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeTemplateRequest.new
571
+ #
572
+ # # Call the delete_notebook_runtime_template method.
573
+ # result = client.delete_notebook_runtime_template request
574
+ #
575
+ # # The returned object is of type Gapic::Operation. You can use it to
576
+ # # check the status of an operation, cancel it, or wait for results.
577
+ # # Here is how to wait for a response.
578
+ # result.wait_until_done! timeout: 60
579
+ # if result.response?
580
+ # p result.response
581
+ # else
582
+ # puts "No response received."
583
+ # end
584
+ #
585
+ def delete_notebook_runtime_template request, options = nil
586
+ raise ::ArgumentError, "request must be provided" if request.nil?
587
+
588
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeTemplateRequest
589
+
590
+ # Converts hash and nil to an options object
591
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
592
+
593
+ # Customize the options with defaults
594
+ metadata = @config.rpcs.delete_notebook_runtime_template.metadata.to_h
595
+
596
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
597
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
598
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
599
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
600
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
601
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
602
+
603
+ header_params = {}
604
+ if request.name
605
+ header_params["name"] = request.name
606
+ end
607
+
608
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
609
+ metadata[:"x-goog-request-params"] ||= request_params_header
610
+
611
+ options.apply_defaults timeout: @config.rpcs.delete_notebook_runtime_template.timeout,
612
+ metadata: metadata,
613
+ retry_policy: @config.rpcs.delete_notebook_runtime_template.retry_policy
614
+
615
+ options.apply_defaults timeout: @config.timeout,
616
+ metadata: @config.metadata,
617
+ retry_policy: @config.retry_policy
618
+
619
+ @notebook_service_stub.call_rpc :delete_notebook_runtime_template, request, options: options do |response, operation|
620
+ response = ::Gapic::Operation.new response, @operations_client, options: options
621
+ yield response, operation if block_given?
622
+ return response
623
+ end
624
+ rescue ::GRPC::BadStatus => e
625
+ raise ::Google::Cloud::Error.from_error(e)
626
+ end
627
+
628
+ ##
629
+ # Assigns a NotebookRuntime to a user for a particular Notebook file. This
630
+ # method will either returns an existing assignment or generates a new one.
631
+ #
632
+ # @overload assign_notebook_runtime(request, options = nil)
633
+ # Pass arguments to `assign_notebook_runtime` via a request object, either of type
634
+ # {::Google::Cloud::AIPlatform::V1::AssignNotebookRuntimeRequest} or an equivalent Hash.
635
+ #
636
+ # @param request [::Google::Cloud::AIPlatform::V1::AssignNotebookRuntimeRequest, ::Hash]
637
+ # A request object representing the call parameters. Required. To specify no
638
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
639
+ # @param options [::Gapic::CallOptions, ::Hash]
640
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
641
+ #
642
+ # @overload assign_notebook_runtime(parent: nil, notebook_runtime_template: nil, notebook_runtime: nil, notebook_runtime_id: nil)
643
+ # Pass arguments to `assign_notebook_runtime` via keyword arguments. Note that at
644
+ # least one keyword argument is required. To specify no parameters, or to keep all
645
+ # the default parameter values, pass an empty Hash as a request object (see above).
646
+ #
647
+ # @param parent [::String]
648
+ # Required. The resource name of the Location to get the NotebookRuntime
649
+ # assignment. Format: `projects/{project}/locations/{location}`
650
+ # @param notebook_runtime_template [::String]
651
+ # Required. The resource name of the NotebookRuntimeTemplate based on which a
652
+ # NotebookRuntime will be assigned (reuse or create a new one).
653
+ # @param notebook_runtime [::Google::Cloud::AIPlatform::V1::NotebookRuntime, ::Hash]
654
+ # Required. Provide runtime specific information (e.g. runtime owner,
655
+ # notebook id) used for NotebookRuntime assignment.
656
+ # @param notebook_runtime_id [::String]
657
+ # Optional. User specified ID for the notebook runtime.
658
+ #
659
+ # @yield [response, operation] Access the result along with the RPC operation
660
+ # @yieldparam response [::Gapic::Operation]
661
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
662
+ #
663
+ # @return [::Gapic::Operation]
664
+ #
665
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
666
+ #
667
+ # @example Basic example
668
+ # require "google/cloud/ai_platform/v1"
669
+ #
670
+ # # Create a client object. The client can be reused for multiple calls.
671
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
672
+ #
673
+ # # Create a request. To set request fields, pass in keyword arguments.
674
+ # request = Google::Cloud::AIPlatform::V1::AssignNotebookRuntimeRequest.new
675
+ #
676
+ # # Call the assign_notebook_runtime method.
677
+ # result = client.assign_notebook_runtime request
678
+ #
679
+ # # The returned object is of type Gapic::Operation. You can use it to
680
+ # # check the status of an operation, cancel it, or wait for results.
681
+ # # Here is how to wait for a response.
682
+ # result.wait_until_done! timeout: 60
683
+ # if result.response?
684
+ # p result.response
685
+ # else
686
+ # puts "No response received."
687
+ # end
688
+ #
689
+ def assign_notebook_runtime request, options = nil
690
+ raise ::ArgumentError, "request must be provided" if request.nil?
691
+
692
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::AssignNotebookRuntimeRequest
693
+
694
+ # Converts hash and nil to an options object
695
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
696
+
697
+ # Customize the options with defaults
698
+ metadata = @config.rpcs.assign_notebook_runtime.metadata.to_h
699
+
700
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
701
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
702
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
703
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
704
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
705
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
706
+
707
+ header_params = {}
708
+ if request.parent
709
+ header_params["parent"] = request.parent
710
+ end
711
+
712
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
713
+ metadata[:"x-goog-request-params"] ||= request_params_header
714
+
715
+ options.apply_defaults timeout: @config.rpcs.assign_notebook_runtime.timeout,
716
+ metadata: metadata,
717
+ retry_policy: @config.rpcs.assign_notebook_runtime.retry_policy
718
+
719
+ options.apply_defaults timeout: @config.timeout,
720
+ metadata: @config.metadata,
721
+ retry_policy: @config.retry_policy
722
+
723
+ @notebook_service_stub.call_rpc :assign_notebook_runtime, request, options: options do |response, operation|
724
+ response = ::Gapic::Operation.new response, @operations_client, options: options
725
+ yield response, operation if block_given?
726
+ return response
727
+ end
728
+ rescue ::GRPC::BadStatus => e
729
+ raise ::Google::Cloud::Error.from_error(e)
730
+ end
731
+
732
+ ##
733
+ # Gets a NotebookRuntime.
734
+ #
735
+ # @overload get_notebook_runtime(request, options = nil)
736
+ # Pass arguments to `get_notebook_runtime` via a request object, either of type
737
+ # {::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeRequest} or an equivalent Hash.
738
+ #
739
+ # @param request [::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeRequest, ::Hash]
740
+ # A request object representing the call parameters. Required. To specify no
741
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
742
+ # @param options [::Gapic::CallOptions, ::Hash]
743
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
744
+ #
745
+ # @overload get_notebook_runtime(name: nil)
746
+ # Pass arguments to `get_notebook_runtime` via keyword arguments. Note that at
747
+ # least one keyword argument is required. To specify no parameters, or to keep all
748
+ # the default parameter values, pass an empty Hash as a request object (see above).
749
+ #
750
+ # @param name [::String]
751
+ # Required. The name of the NotebookRuntime resource.
752
+ # Instead of checking whether the name is in valid NotebookRuntime resource
753
+ # name format, directly throw NotFound exception if there is no such
754
+ # NotebookRuntime in spanner.
755
+ #
756
+ # @yield [response, operation] Access the result along with the RPC operation
757
+ # @yieldparam response [::Google::Cloud::AIPlatform::V1::NotebookRuntime]
758
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
759
+ #
760
+ # @return [::Google::Cloud::AIPlatform::V1::NotebookRuntime]
761
+ #
762
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
763
+ #
764
+ # @example Basic example
765
+ # require "google/cloud/ai_platform/v1"
766
+ #
767
+ # # Create a client object. The client can be reused for multiple calls.
768
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
769
+ #
770
+ # # Create a request. To set request fields, pass in keyword arguments.
771
+ # request = Google::Cloud::AIPlatform::V1::GetNotebookRuntimeRequest.new
772
+ #
773
+ # # Call the get_notebook_runtime method.
774
+ # result = client.get_notebook_runtime request
775
+ #
776
+ # # The returned object is of type Google::Cloud::AIPlatform::V1::NotebookRuntime.
777
+ # p result
778
+ #
779
+ def get_notebook_runtime request, options = nil
780
+ raise ::ArgumentError, "request must be provided" if request.nil?
781
+
782
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::GetNotebookRuntimeRequest
783
+
784
+ # Converts hash and nil to an options object
785
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
786
+
787
+ # Customize the options with defaults
788
+ metadata = @config.rpcs.get_notebook_runtime.metadata.to_h
789
+
790
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
791
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
792
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
793
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
794
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
795
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
796
+
797
+ header_params = {}
798
+ if request.name
799
+ header_params["name"] = request.name
800
+ end
801
+
802
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
803
+ metadata[:"x-goog-request-params"] ||= request_params_header
804
+
805
+ options.apply_defaults timeout: @config.rpcs.get_notebook_runtime.timeout,
806
+ metadata: metadata,
807
+ retry_policy: @config.rpcs.get_notebook_runtime.retry_policy
808
+
809
+ options.apply_defaults timeout: @config.timeout,
810
+ metadata: @config.metadata,
811
+ retry_policy: @config.retry_policy
812
+
813
+ @notebook_service_stub.call_rpc :get_notebook_runtime, request, options: options do |response, operation|
814
+ yield response, operation if block_given?
815
+ return response
816
+ end
817
+ rescue ::GRPC::BadStatus => e
818
+ raise ::Google::Cloud::Error.from_error(e)
819
+ end
820
+
821
+ ##
822
+ # Lists NotebookRuntimes in a Location.
823
+ #
824
+ # @overload list_notebook_runtimes(request, options = nil)
825
+ # Pass arguments to `list_notebook_runtimes` via a request object, either of type
826
+ # {::Google::Cloud::AIPlatform::V1::ListNotebookRuntimesRequest} or an equivalent Hash.
827
+ #
828
+ # @param request [::Google::Cloud::AIPlatform::V1::ListNotebookRuntimesRequest, ::Hash]
829
+ # A request object representing the call parameters. Required. To specify no
830
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
831
+ # @param options [::Gapic::CallOptions, ::Hash]
832
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
833
+ #
834
+ # @overload list_notebook_runtimes(parent: nil, filter: nil, page_size: nil, page_token: nil, read_mask: nil, order_by: nil)
835
+ # Pass arguments to `list_notebook_runtimes` via keyword arguments. Note that at
836
+ # least one keyword argument is required. To specify no parameters, or to keep all
837
+ # the default parameter values, pass an empty Hash as a request object (see above).
838
+ #
839
+ # @param parent [::String]
840
+ # Required. The resource name of the Location from which to list the
841
+ # NotebookRuntimes.
842
+ # Format: `projects/{project}/locations/{location}`
843
+ # @param filter [::String]
844
+ # Optional. An expression for filtering the results of the request. For field
845
+ # names both snake_case and camelCase are supported.
846
+ #
847
+ # * `notebookRuntime` supports = and !=. `notebookRuntime` represents the
848
+ # NotebookRuntime ID,
849
+ # i.e. the last segment of the NotebookRuntime's [resource name]
850
+ # [google.cloud.aiplatform.v1.NotebookRuntime.name].
851
+ # * `displayName` supports = and != and regex.
852
+ # * `notebookRuntimeTemplate` supports = and !=. `notebookRuntimeTemplate`
853
+ # represents the NotebookRuntimeTemplate ID,
854
+ # i.e. the last segment of the NotebookRuntimeTemplate's [resource name]
855
+ # [google.cloud.aiplatform.v1.NotebookRuntimeTemplate.name].
856
+ # * `healthState` supports = and !=. healthState enum: [HEALTHY, UNHEALTHY,
857
+ # HEALTH_STATE_UNSPECIFIED].
858
+ # * `runtimeState` supports = and !=. runtimeState enum:
859
+ # [RUNTIME_STATE_UNSPECIFIED, RUNNING, BEING_STARTED, BEING_STOPPED,
860
+ # STOPPED, BEING_UPGRADED, ERROR, INVALID].
861
+ # * `runtimeUser` supports = and !=.
862
+ # * API version is UI only: `uiState` supports = and !=. uiState enum:
863
+ # [UI_RESOURCE_STATE_UNSPECIFIED, UI_RESOURCE_STATE_BEING_CREATED,
864
+ # UI_RESOURCE_STATE_ACTIVE, UI_RESOURCE_STATE_BEING_DELETED,
865
+ # UI_RESOURCE_STATE_CREATION_FAILED].
866
+ # * `notebookRuntimeType` supports = and !=. notebookRuntimeType enum:
867
+ # [USER_DEFINED, ONE_CLICK].
868
+ #
869
+ # Some examples:
870
+ #
871
+ # * `notebookRuntime="notebookRuntime123"`
872
+ # * `displayName="myDisplayName"` and `displayName=~"myDisplayNameRegex"`
873
+ # * `notebookRuntimeTemplate="notebookRuntimeTemplate321"`
874
+ # * `healthState=HEALTHY`
875
+ # * `runtimeState=RUNNING`
876
+ # * `runtimeUser="test@google.com"`
877
+ # * `uiState=UI_RESOURCE_STATE_BEING_DELETED`
878
+ # * `notebookRuntimeType=USER_DEFINED`
879
+ # @param page_size [::Integer]
880
+ # Optional. The standard list page size.
881
+ # @param page_token [::String]
882
+ # Optional. The standard list page token.
883
+ # Typically obtained via
884
+ # {::Google::Cloud::AIPlatform::V1::ListNotebookRuntimesResponse#next_page_token ListNotebookRuntimesResponse.next_page_token}
885
+ # of the previous
886
+ # {::Google::Cloud::AIPlatform::V1::NotebookService::Client#list_notebook_runtimes NotebookService.ListNotebookRuntimes}
887
+ # call.
888
+ # @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
889
+ # Optional. Mask specifying which fields to read.
890
+ # @param order_by [::String]
891
+ # Optional. A comma-separated list of fields to order by, sorted in ascending
892
+ # order. Use "desc" after a field name for descending. Supported fields:
893
+ #
894
+ # * `display_name`
895
+ # * `create_time`
896
+ # * `update_time`
897
+ #
898
+ # Example: `display_name, create_time desc`.
899
+ #
900
+ # @yield [response, operation] Access the result along with the RPC operation
901
+ # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::NotebookRuntime>]
902
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
903
+ #
904
+ # @return [::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::NotebookRuntime>]
905
+ #
906
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
907
+ #
908
+ # @example Basic example
909
+ # require "google/cloud/ai_platform/v1"
910
+ #
911
+ # # Create a client object. The client can be reused for multiple calls.
912
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
913
+ #
914
+ # # Create a request. To set request fields, pass in keyword arguments.
915
+ # request = Google::Cloud::AIPlatform::V1::ListNotebookRuntimesRequest.new
916
+ #
917
+ # # Call the list_notebook_runtimes method.
918
+ # result = client.list_notebook_runtimes request
919
+ #
920
+ # # The returned object is of type Gapic::PagedEnumerable. You can iterate
921
+ # # over elements, and API calls will be issued to fetch pages as needed.
922
+ # result.each do |item|
923
+ # # Each element is of type ::Google::Cloud::AIPlatform::V1::NotebookRuntime.
924
+ # p item
925
+ # end
926
+ #
927
+ def list_notebook_runtimes request, options = nil
928
+ raise ::ArgumentError, "request must be provided" if request.nil?
929
+
930
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::ListNotebookRuntimesRequest
931
+
932
+ # Converts hash and nil to an options object
933
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
934
+
935
+ # Customize the options with defaults
936
+ metadata = @config.rpcs.list_notebook_runtimes.metadata.to_h
937
+
938
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
939
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
940
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
941
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
942
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
943
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
944
+
945
+ header_params = {}
946
+ if request.parent
947
+ header_params["parent"] = request.parent
948
+ end
949
+
950
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
951
+ metadata[:"x-goog-request-params"] ||= request_params_header
952
+
953
+ options.apply_defaults timeout: @config.rpcs.list_notebook_runtimes.timeout,
954
+ metadata: metadata,
955
+ retry_policy: @config.rpcs.list_notebook_runtimes.retry_policy
956
+
957
+ options.apply_defaults timeout: @config.timeout,
958
+ metadata: @config.metadata,
959
+ retry_policy: @config.retry_policy
960
+
961
+ @notebook_service_stub.call_rpc :list_notebook_runtimes, request, options: options do |response, operation|
962
+ response = ::Gapic::PagedEnumerable.new @notebook_service_stub, :list_notebook_runtimes, request, response, operation, options
963
+ yield response, operation if block_given?
964
+ return response
965
+ end
966
+ rescue ::GRPC::BadStatus => e
967
+ raise ::Google::Cloud::Error.from_error(e)
968
+ end
969
+
970
+ ##
971
+ # Deletes a NotebookRuntime.
972
+ #
973
+ # @overload delete_notebook_runtime(request, options = nil)
974
+ # Pass arguments to `delete_notebook_runtime` via a request object, either of type
975
+ # {::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeRequest} or an equivalent Hash.
976
+ #
977
+ # @param request [::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeRequest, ::Hash]
978
+ # A request object representing the call parameters. Required. To specify no
979
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
980
+ # @param options [::Gapic::CallOptions, ::Hash]
981
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
982
+ #
983
+ # @overload delete_notebook_runtime(name: nil)
984
+ # Pass arguments to `delete_notebook_runtime` via keyword arguments. Note that at
985
+ # least one keyword argument is required. To specify no parameters, or to keep all
986
+ # the default parameter values, pass an empty Hash as a request object (see above).
987
+ #
988
+ # @param name [::String]
989
+ # Required. The name of the NotebookRuntime resource to be deleted.
990
+ # Instead of checking whether the name is in valid NotebookRuntime resource
991
+ # name format, directly throw NotFound exception if there is no such
992
+ # NotebookRuntime in spanner.
993
+ #
994
+ # @yield [response, operation] Access the result along with the RPC operation
995
+ # @yieldparam response [::Gapic::Operation]
996
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
997
+ #
998
+ # @return [::Gapic::Operation]
999
+ #
1000
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1001
+ #
1002
+ # @example Basic example
1003
+ # require "google/cloud/ai_platform/v1"
1004
+ #
1005
+ # # Create a client object. The client can be reused for multiple calls.
1006
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
1007
+ #
1008
+ # # Create a request. To set request fields, pass in keyword arguments.
1009
+ # request = Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeRequest.new
1010
+ #
1011
+ # # Call the delete_notebook_runtime method.
1012
+ # result = client.delete_notebook_runtime request
1013
+ #
1014
+ # # The returned object is of type Gapic::Operation. You can use it to
1015
+ # # check the status of an operation, cancel it, or wait for results.
1016
+ # # Here is how to wait for a response.
1017
+ # result.wait_until_done! timeout: 60
1018
+ # if result.response?
1019
+ # p result.response
1020
+ # else
1021
+ # puts "No response received."
1022
+ # end
1023
+ #
1024
+ def delete_notebook_runtime request, options = nil
1025
+ raise ::ArgumentError, "request must be provided" if request.nil?
1026
+
1027
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::DeleteNotebookRuntimeRequest
1028
+
1029
+ # Converts hash and nil to an options object
1030
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1031
+
1032
+ # Customize the options with defaults
1033
+ metadata = @config.rpcs.delete_notebook_runtime.metadata.to_h
1034
+
1035
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1036
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1037
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1038
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
1039
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1040
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1041
+
1042
+ header_params = {}
1043
+ if request.name
1044
+ header_params["name"] = request.name
1045
+ end
1046
+
1047
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
1048
+ metadata[:"x-goog-request-params"] ||= request_params_header
1049
+
1050
+ options.apply_defaults timeout: @config.rpcs.delete_notebook_runtime.timeout,
1051
+ metadata: metadata,
1052
+ retry_policy: @config.rpcs.delete_notebook_runtime.retry_policy
1053
+
1054
+ options.apply_defaults timeout: @config.timeout,
1055
+ metadata: @config.metadata,
1056
+ retry_policy: @config.retry_policy
1057
+
1058
+ @notebook_service_stub.call_rpc :delete_notebook_runtime, request, options: options do |response, operation|
1059
+ response = ::Gapic::Operation.new response, @operations_client, options: options
1060
+ yield response, operation if block_given?
1061
+ return response
1062
+ end
1063
+ rescue ::GRPC::BadStatus => e
1064
+ raise ::Google::Cloud::Error.from_error(e)
1065
+ end
1066
+
1067
+ ##
1068
+ # Upgrades a NotebookRuntime.
1069
+ #
1070
+ # @overload upgrade_notebook_runtime(request, options = nil)
1071
+ # Pass arguments to `upgrade_notebook_runtime` via a request object, either of type
1072
+ # {::Google::Cloud::AIPlatform::V1::UpgradeNotebookRuntimeRequest} or an equivalent Hash.
1073
+ #
1074
+ # @param request [::Google::Cloud::AIPlatform::V1::UpgradeNotebookRuntimeRequest, ::Hash]
1075
+ # A request object representing the call parameters. Required. To specify no
1076
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1077
+ # @param options [::Gapic::CallOptions, ::Hash]
1078
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1079
+ #
1080
+ # @overload upgrade_notebook_runtime(name: nil)
1081
+ # Pass arguments to `upgrade_notebook_runtime` via keyword arguments. Note that at
1082
+ # least one keyword argument is required. To specify no parameters, or to keep all
1083
+ # the default parameter values, pass an empty Hash as a request object (see above).
1084
+ #
1085
+ # @param name [::String]
1086
+ # Required. The name of the NotebookRuntime resource to be upgrade.
1087
+ # Instead of checking whether the name is in valid NotebookRuntime resource
1088
+ # name format, directly throw NotFound exception if there is no such
1089
+ # NotebookRuntime in spanner.
1090
+ #
1091
+ # @yield [response, operation] Access the result along with the RPC operation
1092
+ # @yieldparam response [::Gapic::Operation]
1093
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1094
+ #
1095
+ # @return [::Gapic::Operation]
1096
+ #
1097
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1098
+ #
1099
+ # @example Basic example
1100
+ # require "google/cloud/ai_platform/v1"
1101
+ #
1102
+ # # Create a client object. The client can be reused for multiple calls.
1103
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
1104
+ #
1105
+ # # Create a request. To set request fields, pass in keyword arguments.
1106
+ # request = Google::Cloud::AIPlatform::V1::UpgradeNotebookRuntimeRequest.new
1107
+ #
1108
+ # # Call the upgrade_notebook_runtime method.
1109
+ # result = client.upgrade_notebook_runtime request
1110
+ #
1111
+ # # The returned object is of type Gapic::Operation. You can use it to
1112
+ # # check the status of an operation, cancel it, or wait for results.
1113
+ # # Here is how to wait for a response.
1114
+ # result.wait_until_done! timeout: 60
1115
+ # if result.response?
1116
+ # p result.response
1117
+ # else
1118
+ # puts "No response received."
1119
+ # end
1120
+ #
1121
+ def upgrade_notebook_runtime request, options = nil
1122
+ raise ::ArgumentError, "request must be provided" if request.nil?
1123
+
1124
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::UpgradeNotebookRuntimeRequest
1125
+
1126
+ # Converts hash and nil to an options object
1127
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1128
+
1129
+ # Customize the options with defaults
1130
+ metadata = @config.rpcs.upgrade_notebook_runtime.metadata.to_h
1131
+
1132
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1133
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1134
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1135
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
1136
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1137
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1138
+
1139
+ header_params = {}
1140
+ if request.name
1141
+ header_params["name"] = request.name
1142
+ end
1143
+
1144
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
1145
+ metadata[:"x-goog-request-params"] ||= request_params_header
1146
+
1147
+ options.apply_defaults timeout: @config.rpcs.upgrade_notebook_runtime.timeout,
1148
+ metadata: metadata,
1149
+ retry_policy: @config.rpcs.upgrade_notebook_runtime.retry_policy
1150
+
1151
+ options.apply_defaults timeout: @config.timeout,
1152
+ metadata: @config.metadata,
1153
+ retry_policy: @config.retry_policy
1154
+
1155
+ @notebook_service_stub.call_rpc :upgrade_notebook_runtime, request, options: options do |response, operation|
1156
+ response = ::Gapic::Operation.new response, @operations_client, options: options
1157
+ yield response, operation if block_given?
1158
+ return response
1159
+ end
1160
+ rescue ::GRPC::BadStatus => e
1161
+ raise ::Google::Cloud::Error.from_error(e)
1162
+ end
1163
+
1164
+ ##
1165
+ # Starts a NotebookRuntime.
1166
+ #
1167
+ # @overload start_notebook_runtime(request, options = nil)
1168
+ # Pass arguments to `start_notebook_runtime` via a request object, either of type
1169
+ # {::Google::Cloud::AIPlatform::V1::StartNotebookRuntimeRequest} or an equivalent Hash.
1170
+ #
1171
+ # @param request [::Google::Cloud::AIPlatform::V1::StartNotebookRuntimeRequest, ::Hash]
1172
+ # A request object representing the call parameters. Required. To specify no
1173
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1174
+ # @param options [::Gapic::CallOptions, ::Hash]
1175
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1176
+ #
1177
+ # @overload start_notebook_runtime(name: nil)
1178
+ # Pass arguments to `start_notebook_runtime` via keyword arguments. Note that at
1179
+ # least one keyword argument is required. To specify no parameters, or to keep all
1180
+ # the default parameter values, pass an empty Hash as a request object (see above).
1181
+ #
1182
+ # @param name [::String]
1183
+ # Required. The name of the NotebookRuntime resource to be started.
1184
+ # Instead of checking whether the name is in valid NotebookRuntime resource
1185
+ # name format, directly throw NotFound exception if there is no such
1186
+ # NotebookRuntime in spanner.
1187
+ #
1188
+ # @yield [response, operation] Access the result along with the RPC operation
1189
+ # @yieldparam response [::Gapic::Operation]
1190
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1191
+ #
1192
+ # @return [::Gapic::Operation]
1193
+ #
1194
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1195
+ #
1196
+ # @example Basic example
1197
+ # require "google/cloud/ai_platform/v1"
1198
+ #
1199
+ # # Create a client object. The client can be reused for multiple calls.
1200
+ # client = Google::Cloud::AIPlatform::V1::NotebookService::Client.new
1201
+ #
1202
+ # # Create a request. To set request fields, pass in keyword arguments.
1203
+ # request = Google::Cloud::AIPlatform::V1::StartNotebookRuntimeRequest.new
1204
+ #
1205
+ # # Call the start_notebook_runtime method.
1206
+ # result = client.start_notebook_runtime request
1207
+ #
1208
+ # # The returned object is of type Gapic::Operation. You can use it to
1209
+ # # check the status of an operation, cancel it, or wait for results.
1210
+ # # Here is how to wait for a response.
1211
+ # result.wait_until_done! timeout: 60
1212
+ # if result.response?
1213
+ # p result.response
1214
+ # else
1215
+ # puts "No response received."
1216
+ # end
1217
+ #
1218
+ def start_notebook_runtime request, options = nil
1219
+ raise ::ArgumentError, "request must be provided" if request.nil?
1220
+
1221
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::StartNotebookRuntimeRequest
1222
+
1223
+ # Converts hash and nil to an options object
1224
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1225
+
1226
+ # Customize the options with defaults
1227
+ metadata = @config.rpcs.start_notebook_runtime.metadata.to_h
1228
+
1229
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1230
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1231
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1232
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION
1233
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1234
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1235
+
1236
+ header_params = {}
1237
+ if request.name
1238
+ header_params["name"] = request.name
1239
+ end
1240
+
1241
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
1242
+ metadata[:"x-goog-request-params"] ||= request_params_header
1243
+
1244
+ options.apply_defaults timeout: @config.rpcs.start_notebook_runtime.timeout,
1245
+ metadata: metadata,
1246
+ retry_policy: @config.rpcs.start_notebook_runtime.retry_policy
1247
+
1248
+ options.apply_defaults timeout: @config.timeout,
1249
+ metadata: @config.metadata,
1250
+ retry_policy: @config.retry_policy
1251
+
1252
+ @notebook_service_stub.call_rpc :start_notebook_runtime, request, options: options do |response, operation|
1253
+ response = ::Gapic::Operation.new response, @operations_client, options: options
1254
+ yield response, operation if block_given?
1255
+ return response
1256
+ end
1257
+ rescue ::GRPC::BadStatus => e
1258
+ raise ::Google::Cloud::Error.from_error(e)
1259
+ end
1260
+
1261
+ ##
1262
+ # Configuration class for the NotebookService API.
1263
+ #
1264
+ # This class represents the configuration for NotebookService,
1265
+ # providing control over timeouts, retry behavior, logging, transport
1266
+ # parameters, and other low-level controls. Certain parameters can also be
1267
+ # applied individually to specific RPCs. See
1268
+ # {::Google::Cloud::AIPlatform::V1::NotebookService::Client::Configuration::Rpcs}
1269
+ # for a list of RPCs that can be configured independently.
1270
+ #
1271
+ # Configuration can be applied globally to all clients, or to a single client
1272
+ # on construction.
1273
+ #
1274
+ # @example
1275
+ #
1276
+ # # Modify the global config, setting the timeout for
1277
+ # # create_notebook_runtime_template to 20 seconds,
1278
+ # # and all remaining timeouts to 10 seconds.
1279
+ # ::Google::Cloud::AIPlatform::V1::NotebookService::Client.configure do |config|
1280
+ # config.timeout = 10.0
1281
+ # config.rpcs.create_notebook_runtime_template.timeout = 20.0
1282
+ # end
1283
+ #
1284
+ # # Apply the above configuration only to a new client.
1285
+ # client = ::Google::Cloud::AIPlatform::V1::NotebookService::Client.new do |config|
1286
+ # config.timeout = 10.0
1287
+ # config.rpcs.create_notebook_runtime_template.timeout = 20.0
1288
+ # end
1289
+ #
1290
+ # @!attribute [rw] endpoint
1291
+ # A custom service endpoint, as a hostname or hostname:port. The default is
1292
+ # nil, indicating to use the default endpoint in the current universe domain.
1293
+ # @return [::String,nil]
1294
+ # @!attribute [rw] credentials
1295
+ # Credentials to send with calls. You may provide any of the following types:
1296
+ # * (`String`) The path to a service account key file in JSON format
1297
+ # * (`Hash`) A service account key as a Hash
1298
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
1299
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
1300
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
1301
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
1302
+ # * (`GRPC::Core::Channel`) a gRPC channel with included credentials
1303
+ # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
1304
+ # * (`nil`) indicating no credentials
1305
+ # @return [::Object]
1306
+ # @!attribute [rw] scope
1307
+ # The OAuth scopes
1308
+ # @return [::Array<::String>]
1309
+ # @!attribute [rw] lib_name
1310
+ # The library name as recorded in instrumentation and logging
1311
+ # @return [::String]
1312
+ # @!attribute [rw] lib_version
1313
+ # The library version as recorded in instrumentation and logging
1314
+ # @return [::String]
1315
+ # @!attribute [rw] channel_args
1316
+ # Extra parameters passed to the gRPC channel. Note: this is ignored if a
1317
+ # `GRPC::Core::Channel` object is provided as the credential.
1318
+ # @return [::Hash]
1319
+ # @!attribute [rw] interceptors
1320
+ # An array of interceptors that are run before calls are executed.
1321
+ # @return [::Array<::GRPC::ClientInterceptor>]
1322
+ # @!attribute [rw] timeout
1323
+ # The call timeout in seconds.
1324
+ # @return [::Numeric]
1325
+ # @!attribute [rw] metadata
1326
+ # Additional gRPC headers to be sent with the call.
1327
+ # @return [::Hash{::Symbol=>::String}]
1328
+ # @!attribute [rw] retry_policy
1329
+ # The retry policy. The value is a hash with the following keys:
1330
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
1331
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
1332
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
1333
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
1334
+ # trigger a retry.
1335
+ # @return [::Hash]
1336
+ # @!attribute [rw] quota_project
1337
+ # A separate project against which to charge quota.
1338
+ # @return [::String]
1339
+ # @!attribute [rw] universe_domain
1340
+ # The universe domain within which to make requests. This determines the
1341
+ # default endpoint URL. The default value of nil uses the environment
1342
+ # universe (usually the default "googleapis.com" universe).
1343
+ # @return [::String,nil]
1344
+ #
1345
+ class Configuration
1346
+ extend ::Gapic::Config
1347
+
1348
+ # @private
1349
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
1350
+ DEFAULT_ENDPOINT = "aiplatform.googleapis.com"
1351
+
1352
+ config_attr :endpoint, nil, ::String, nil
1353
+ config_attr :credentials, nil do |value|
1354
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
1355
+ allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
1356
+ allowed.any? { |klass| klass === value }
1357
+ end
1358
+ config_attr :scope, nil, ::String, ::Array, nil
1359
+ config_attr :lib_name, nil, ::String, nil
1360
+ config_attr :lib_version, nil, ::String, nil
1361
+ config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
1362
+ config_attr :interceptors, nil, ::Array, nil
1363
+ config_attr :timeout, nil, ::Numeric, nil
1364
+ config_attr :metadata, nil, ::Hash, nil
1365
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
1366
+ config_attr :quota_project, nil, ::String, nil
1367
+ config_attr :universe_domain, nil, ::String, nil
1368
+
1369
+ # @private
1370
+ def initialize parent_config = nil
1371
+ @parent_config = parent_config unless parent_config.nil?
1372
+
1373
+ yield self if block_given?
1374
+ end
1375
+
1376
+ ##
1377
+ # Configurations for individual RPCs
1378
+ # @return [Rpcs]
1379
+ #
1380
+ def rpcs
1381
+ @rpcs ||= begin
1382
+ parent_rpcs = nil
1383
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
1384
+ Rpcs.new parent_rpcs
1385
+ end
1386
+ end
1387
+
1388
+ ##
1389
+ # Configuration for the channel pool
1390
+ # @return [::Gapic::ServiceStub::ChannelPool::Configuration]
1391
+ #
1392
+ def channel_pool
1393
+ @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new
1394
+ end
1395
+
1396
+ ##
1397
+ # Configuration RPC class for the NotebookService API.
1398
+ #
1399
+ # Includes fields providing the configuration for each RPC in this service.
1400
+ # Each configuration object is of type `Gapic::Config::Method` and includes
1401
+ # the following configuration fields:
1402
+ #
1403
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
1404
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers
1405
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
1406
+ # include the following keys:
1407
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
1408
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
1409
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
1410
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
1411
+ # trigger a retry.
1412
+ #
1413
+ class Rpcs
1414
+ ##
1415
+ # RPC-specific configuration for `create_notebook_runtime_template`
1416
+ # @return [::Gapic::Config::Method]
1417
+ #
1418
+ attr_reader :create_notebook_runtime_template
1419
+ ##
1420
+ # RPC-specific configuration for `get_notebook_runtime_template`
1421
+ # @return [::Gapic::Config::Method]
1422
+ #
1423
+ attr_reader :get_notebook_runtime_template
1424
+ ##
1425
+ # RPC-specific configuration for `list_notebook_runtime_templates`
1426
+ # @return [::Gapic::Config::Method]
1427
+ #
1428
+ attr_reader :list_notebook_runtime_templates
1429
+ ##
1430
+ # RPC-specific configuration for `delete_notebook_runtime_template`
1431
+ # @return [::Gapic::Config::Method]
1432
+ #
1433
+ attr_reader :delete_notebook_runtime_template
1434
+ ##
1435
+ # RPC-specific configuration for `assign_notebook_runtime`
1436
+ # @return [::Gapic::Config::Method]
1437
+ #
1438
+ attr_reader :assign_notebook_runtime
1439
+ ##
1440
+ # RPC-specific configuration for `get_notebook_runtime`
1441
+ # @return [::Gapic::Config::Method]
1442
+ #
1443
+ attr_reader :get_notebook_runtime
1444
+ ##
1445
+ # RPC-specific configuration for `list_notebook_runtimes`
1446
+ # @return [::Gapic::Config::Method]
1447
+ #
1448
+ attr_reader :list_notebook_runtimes
1449
+ ##
1450
+ # RPC-specific configuration for `delete_notebook_runtime`
1451
+ # @return [::Gapic::Config::Method]
1452
+ #
1453
+ attr_reader :delete_notebook_runtime
1454
+ ##
1455
+ # RPC-specific configuration for `upgrade_notebook_runtime`
1456
+ # @return [::Gapic::Config::Method]
1457
+ #
1458
+ attr_reader :upgrade_notebook_runtime
1459
+ ##
1460
+ # RPC-specific configuration for `start_notebook_runtime`
1461
+ # @return [::Gapic::Config::Method]
1462
+ #
1463
+ attr_reader :start_notebook_runtime
1464
+
1465
+ # @private
1466
+ def initialize parent_rpcs = nil
1467
+ create_notebook_runtime_template_config = parent_rpcs.create_notebook_runtime_template if parent_rpcs.respond_to? :create_notebook_runtime_template
1468
+ @create_notebook_runtime_template = ::Gapic::Config::Method.new create_notebook_runtime_template_config
1469
+ get_notebook_runtime_template_config = parent_rpcs.get_notebook_runtime_template if parent_rpcs.respond_to? :get_notebook_runtime_template
1470
+ @get_notebook_runtime_template = ::Gapic::Config::Method.new get_notebook_runtime_template_config
1471
+ list_notebook_runtime_templates_config = parent_rpcs.list_notebook_runtime_templates if parent_rpcs.respond_to? :list_notebook_runtime_templates
1472
+ @list_notebook_runtime_templates = ::Gapic::Config::Method.new list_notebook_runtime_templates_config
1473
+ delete_notebook_runtime_template_config = parent_rpcs.delete_notebook_runtime_template if parent_rpcs.respond_to? :delete_notebook_runtime_template
1474
+ @delete_notebook_runtime_template = ::Gapic::Config::Method.new delete_notebook_runtime_template_config
1475
+ assign_notebook_runtime_config = parent_rpcs.assign_notebook_runtime if parent_rpcs.respond_to? :assign_notebook_runtime
1476
+ @assign_notebook_runtime = ::Gapic::Config::Method.new assign_notebook_runtime_config
1477
+ get_notebook_runtime_config = parent_rpcs.get_notebook_runtime if parent_rpcs.respond_to? :get_notebook_runtime
1478
+ @get_notebook_runtime = ::Gapic::Config::Method.new get_notebook_runtime_config
1479
+ list_notebook_runtimes_config = parent_rpcs.list_notebook_runtimes if parent_rpcs.respond_to? :list_notebook_runtimes
1480
+ @list_notebook_runtimes = ::Gapic::Config::Method.new list_notebook_runtimes_config
1481
+ delete_notebook_runtime_config = parent_rpcs.delete_notebook_runtime if parent_rpcs.respond_to? :delete_notebook_runtime
1482
+ @delete_notebook_runtime = ::Gapic::Config::Method.new delete_notebook_runtime_config
1483
+ upgrade_notebook_runtime_config = parent_rpcs.upgrade_notebook_runtime if parent_rpcs.respond_to? :upgrade_notebook_runtime
1484
+ @upgrade_notebook_runtime = ::Gapic::Config::Method.new upgrade_notebook_runtime_config
1485
+ start_notebook_runtime_config = parent_rpcs.start_notebook_runtime if parent_rpcs.respond_to? :start_notebook_runtime
1486
+ @start_notebook_runtime = ::Gapic::Config::Method.new start_notebook_runtime_config
1487
+
1488
+ yield self if block_given?
1489
+ end
1490
+ end
1491
+ end
1492
+ end
1493
+ end
1494
+ end
1495
+ end
1496
+ end
1497
+ end