Class RaySpec.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
- com.google.cloud.aiplatform.v1beta1.RaySpec.Builder
-
- All Implemented Interfaces:
RaySpecOrBuilder
,com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Cloneable
- Enclosing class:
- RaySpec
public static final class RaySpec.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder> implements RaySpecOrBuilder
Configuration information for the Ray cluster. For experimental launch, Ray cluster creation and Persistent cluster creation are 1:1 mapping: We will provision all the nodes within the Persistent cluster as Ray nodes.
Protobuf typegoogle.cloud.aiplatform.v1beta1.RaySpec
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description RaySpec.Builder
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
RaySpec
build()
RaySpec
buildPartial()
RaySpec.Builder
clear()
RaySpec.Builder
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
RaySpec.Builder
clearHeadNodeResourcePoolId()
Optional.RaySpec.Builder
clearImageUri()
Optional.RaySpec.Builder
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
RaySpec.Builder
clearResourcePoolImages()
RaySpec.Builder
clone()
boolean
containsResourcePoolImages(String key)
Optional.RaySpec
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
com.google.protobuf.Descriptors.Descriptor
getDescriptorForType()
String
getHeadNodeResourcePoolId()
Optional.com.google.protobuf.ByteString
getHeadNodeResourcePoolIdBytes()
Optional.String
getImageUri()
Optional.com.google.protobuf.ByteString
getImageUriBytes()
Optional.Map<String,String>
getMutableResourcePoolImages()
Deprecated.Map<String,String>
getResourcePoolImages()
Deprecated.int
getResourcePoolImagesCount()
Optional.Map<String,String>
getResourcePoolImagesMap()
Optional.String
getResourcePoolImagesOrDefault(String key, String defaultValue)
Optional.String
getResourcePoolImagesOrThrow(String key)
Optional.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
protected com.google.protobuf.MapField
internalGetMapField(int number)
protected com.google.protobuf.MapField
internalGetMutableMapField(int number)
boolean
isInitialized()
RaySpec.Builder
mergeFrom(RaySpec other)
RaySpec.Builder
mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
RaySpec.Builder
mergeFrom(com.google.protobuf.Message other)
RaySpec.Builder
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
RaySpec.Builder
putAllResourcePoolImages(Map<String,String> values)
Optional.RaySpec.Builder
putResourcePoolImages(String key, String value)
Optional.RaySpec.Builder
removeResourcePoolImages(String key)
Optional.RaySpec.Builder
setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
RaySpec.Builder
setHeadNodeResourcePoolId(String value)
Optional.RaySpec.Builder
setHeadNodeResourcePoolIdBytes(com.google.protobuf.ByteString value)
Optional.RaySpec.Builder
setImageUri(String value)
Optional.RaySpec.Builder
setImageUriBytes(com.google.protobuf.ByteString value)
Optional.RaySpec.Builder
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
RaySpec.Builder
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
-
Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetMapField
protected com.google.protobuf.MapField internalGetMapField(int number)
- Overrides:
internalGetMapField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
internalGetMutableMapField
protected com.google.protobuf.MapField internalGetMutableMapField(int number)
- Overrides:
internalGetMutableMapField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
clear
public RaySpec.Builder clear()
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
getDefaultInstanceForType
public RaySpec getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
public RaySpec build()
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public RaySpec buildPartial()
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
clone
public RaySpec.Builder clone()
- Specified by:
clone
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clone
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clone
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
setField
public RaySpec.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
setField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
clearField
public RaySpec.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
clearOneof
public RaySpec.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneof
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearOneof
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
setRepeatedField
public RaySpec.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
- Specified by:
setRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
addRepeatedField
public RaySpec.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
addRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
addRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
mergeFrom
public RaySpec.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<RaySpec.Builder>
-
mergeFrom
public RaySpec.Builder mergeFrom(RaySpec other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
mergeFrom
public RaySpec.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<RaySpec.Builder>
- Throws:
IOException
-
getImageUri
public String getImageUri()
Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.
string image_uri = 1 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getImageUri
in interfaceRaySpecOrBuilder
- Returns:
- The imageUri.
-
getImageUriBytes
public com.google.protobuf.ByteString getImageUriBytes()
Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.
string image_uri = 1 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getImageUriBytes
in interfaceRaySpecOrBuilder
- Returns:
- The bytes for imageUri.
-
setImageUri
public RaySpec.Builder setImageUri(String value)
Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.
string image_uri = 1 [(.google.api.field_behavior) = OPTIONAL];
- Parameters:
value
- The imageUri to set.- Returns:
- This builder for chaining.
-
clearImageUri
public RaySpec.Builder clearImageUri()
Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.
string image_uri = 1 [(.google.api.field_behavior) = OPTIONAL];
- Returns:
- This builder for chaining.
-
setImageUriBytes
public RaySpec.Builder setImageUriBytes(com.google.protobuf.ByteString value)
Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.
string image_uri = 1 [(.google.api.field_behavior) = OPTIONAL];
- Parameters:
value
- The bytes for imageUri to set.- Returns:
- This builder for chaining.
-
getResourcePoolImagesCount
public int getResourcePoolImagesCount()
Description copied from interface:RaySpecOrBuilder
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getResourcePoolImagesCount
in interfaceRaySpecOrBuilder
-
containsResourcePoolImages
public boolean containsResourcePoolImages(String key)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
containsResourcePoolImages
in interfaceRaySpecOrBuilder
-
getResourcePoolImages
@Deprecated public Map<String,String> getResourcePoolImages()
Deprecated.UsegetResourcePoolImagesMap()
instead.- Specified by:
getResourcePoolImages
in interfaceRaySpecOrBuilder
-
getResourcePoolImagesMap
public Map<String,String> getResourcePoolImagesMap()
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getResourcePoolImagesMap
in interfaceRaySpecOrBuilder
-
getResourcePoolImagesOrDefault
public String getResourcePoolImagesOrDefault(String key, String defaultValue)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getResourcePoolImagesOrDefault
in interfaceRaySpecOrBuilder
-
getResourcePoolImagesOrThrow
public String getResourcePoolImagesOrThrow(String key)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getResourcePoolImagesOrThrow
in interfaceRaySpecOrBuilder
-
clearResourcePoolImages
public RaySpec.Builder clearResourcePoolImages()
-
removeResourcePoolImages
public RaySpec.Builder removeResourcePoolImages(String key)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
-
getMutableResourcePoolImages
@Deprecated public Map<String,String> getMutableResourcePoolImages()
Deprecated.Use alternate mutation accessors instead.
-
putResourcePoolImages
public RaySpec.Builder putResourcePoolImages(String key, String value)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
-
putAllResourcePoolImages
public RaySpec.Builder putAllResourcePoolImages(Map<String,String> values)
Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
map<string, string> resource_pool_images = 6 [(.google.api.field_behavior) = OPTIONAL];
-
getHeadNodeResourcePoolId
public String getHeadNodeResourcePoolId()
Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.
string head_node_resource_pool_id = 7 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getHeadNodeResourcePoolId
in interfaceRaySpecOrBuilder
- Returns:
- The headNodeResourcePoolId.
-
getHeadNodeResourcePoolIdBytes
public com.google.protobuf.ByteString getHeadNodeResourcePoolIdBytes()
Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.
string head_node_resource_pool_id = 7 [(.google.api.field_behavior) = OPTIONAL];
- Specified by:
getHeadNodeResourcePoolIdBytes
in interfaceRaySpecOrBuilder
- Returns:
- The bytes for headNodeResourcePoolId.
-
setHeadNodeResourcePoolId
public RaySpec.Builder setHeadNodeResourcePoolId(String value)
Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.
string head_node_resource_pool_id = 7 [(.google.api.field_behavior) = OPTIONAL];
- Parameters:
value
- The headNodeResourcePoolId to set.- Returns:
- This builder for chaining.
-
clearHeadNodeResourcePoolId
public RaySpec.Builder clearHeadNodeResourcePoolId()
Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.
string head_node_resource_pool_id = 7 [(.google.api.field_behavior) = OPTIONAL];
- Returns:
- This builder for chaining.
-
setHeadNodeResourcePoolIdBytes
public RaySpec.Builder setHeadNodeResourcePoolIdBytes(com.google.protobuf.ByteString value)
Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.
string head_node_resource_pool_id = 7 [(.google.api.field_behavior) = OPTIONAL];
- Parameters:
value
- The bytes for headNodeResourcePoolId to set.- Returns:
- This builder for chaining.
-
setUnknownFields
public final RaySpec.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
mergeUnknownFields
public final RaySpec.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<RaySpec.Builder>
-
-