Class WorkerPool (3.17.0)

public final class WorkerPool extends GeneratedMessageV3 implements WorkerPoolOrBuilder

Configuration for a WorkerPool. Cloud Build owns and maintains a pool of workers for general use and have no access to a project's private network. By default, builds submitted to Cloud Build will use a worker from this pool. If your build needs access to resources on a private network, create and use a WorkerPool to run your builds. Private WorkerPools give your builds access to any single VPC network that you administer, including any on-prem resources connected to that VPC network. For an overview of private pools, see Private pools overview.

Protobuf type google.devtools.cloudbuild.v1.WorkerPool

Implements

WorkerPoolOrBuilder

Static Fields

ANNOTATIONS_FIELD_NUMBER

public static final int ANNOTATIONS_FIELD_NUMBER
Field Value
TypeDescription
int

CREATE_TIME_FIELD_NUMBER

public static final int CREATE_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

DELETE_TIME_FIELD_NUMBER

public static final int DELETE_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

DISPLAY_NAME_FIELD_NUMBER

public static final int DISPLAY_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

ETAG_FIELD_NUMBER

public static final int ETAG_FIELD_NUMBER
Field Value
TypeDescription
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

PRIVATE_POOL_V1_CONFIG_FIELD_NUMBER

public static final int PRIVATE_POOL_V1_CONFIG_FIELD_NUMBER
Field Value
TypeDescription
int

STATE_FIELD_NUMBER

public static final int STATE_FIELD_NUMBER
Field Value
TypeDescription
int

UID_FIELD_NUMBER

public static final int UID_FIELD_NUMBER
Field Value
TypeDescription
int

UPDATE_TIME_FIELD_NUMBER

public static final int UPDATE_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static WorkerPool getDefaultInstance()
Returns
TypeDescription
WorkerPool

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static WorkerPool.Builder newBuilder()
Returns
TypeDescription
WorkerPool.Builder

newBuilder(WorkerPool prototype)

public static WorkerPool.Builder newBuilder(WorkerPool prototype)
Parameter
NameDescription
prototypeWorkerPool
Returns
TypeDescription
WorkerPool.Builder

parseDelimitedFrom(InputStream input)

public static WorkerPool parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static WorkerPool parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static WorkerPool parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static WorkerPool parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static WorkerPool parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static WorkerPool parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static WorkerPool parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WorkerPool
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<WorkerPool> parser()
Returns
TypeDescription
Parser<WorkerPool>

Methods

containsAnnotations(String key)

public boolean containsAnnotations(String key)

User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.

map<string, string> annotations = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getAnnotations()

public Map<String,String> getAnnotations()

Use #getAnnotationsMap() instead.

Returns
TypeDescription
Map<String,String>

getAnnotationsCount()

public int getAnnotationsCount()

User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.

map<string, string> annotations = 4;

Returns
TypeDescription
int

getAnnotationsMap()

public Map<String,String> getAnnotationsMap()

User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.

map<string, string> annotations = 4;

Returns
TypeDescription
Map<String,String>

getAnnotationsOrDefault(String key, String defaultValue)

public String getAnnotationsOrDefault(String key, String defaultValue)

User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.

map<string, string> annotations = 4;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getAnnotationsOrThrow(String key)

public String getAnnotationsOrThrow(String key)

User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.

map<string, string> annotations = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

getConfigCase()

public WorkerPool.ConfigCase getConfigCase()
Returns
TypeDescription
WorkerPool.ConfigCase

getCreateTime()

public Timestamp getCreateTime()

Output only. Time at which the request to create the WorkerPool was received.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The createTime.

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. Time at which the request to create the WorkerPool was received.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getDefaultInstanceForType()

public WorkerPool getDefaultInstanceForType()
Returns
TypeDescription
WorkerPool

getDeleteTime()

public Timestamp getDeleteTime()

Output only. Time at which the request to delete the WorkerPool was received.

.google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The deleteTime.

getDeleteTimeOrBuilder()

public TimestampOrBuilder getDeleteTimeOrBuilder()

Output only. Time at which the request to delete the WorkerPool was received.

.google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getDisplayName()

public String getDisplayName()

A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.

string display_name = 2;

Returns
TypeDescription
String

The displayName.

getDisplayNameBytes()

public ByteString getDisplayNameBytes()

A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.

string display_name = 2;

Returns
TypeDescription
ByteString

The bytes for displayName.

getEtag()

public String getEtag()

Output only. Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.

string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The etag.

getEtagBytes()

public ByteString getEtagBytes()

Output only. Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.

string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for etag.

getName()

public String getName()

Output only. The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Output only. The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for name.

getParserForType()

public Parser<WorkerPool> getParserForType()
Returns
TypeDescription
Parser<WorkerPool>
Overrides

getPrivatePoolV1Config()

public PrivatePoolV1Config getPrivatePoolV1Config()

Private Pool using a v1 configuration.

.google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12;

Returns
TypeDescription
PrivatePoolV1Config

The privatePoolV1Config.

getPrivatePoolV1ConfigOrBuilder()

public PrivatePoolV1ConfigOrBuilder getPrivatePoolV1ConfigOrBuilder()

Private Pool using a v1 configuration.

.google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12;

Returns
TypeDescription
PrivatePoolV1ConfigOrBuilder

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getState()

public WorkerPool.State getState()

Output only. WorkerPool state.

.google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
WorkerPool.State

The state.

getStateValue()

public int getStateValue()

Output only. WorkerPool state.

.google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The enum numeric value on the wire for state.

getUid()

public String getUid()

Output only. A unique identifier for the WorkerPool.

string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The uid.

getUidBytes()

public ByteString getUidBytes()

Output only. A unique identifier for the WorkerPool.

string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for uid.

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

getUpdateTime()

public Timestamp getUpdateTime()

Output only. Time at which the request to update the WorkerPool was received.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The updateTime.

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. Time at which the request to update the WorkerPool was received.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

hasCreateTime()

public boolean hasCreateTime()

Output only. Time at which the request to create the WorkerPool was received.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the createTime field is set.

hasDeleteTime()

public boolean hasDeleteTime()

Output only. Time at which the request to delete the WorkerPool was received.

.google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the deleteTime field is set.

hasPrivatePoolV1Config()

public boolean hasPrivatePoolV1Config()

Private Pool using a v1 configuration.

.google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12;

Returns
TypeDescription
boolean

Whether the privatePoolV1Config field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. Time at which the request to update the WorkerPool was received.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the updateTime field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapField(int number)

protected MapField internalGetMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public WorkerPool.Builder newBuilderForType()
Returns
TypeDescription
WorkerPool.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected WorkerPool.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
WorkerPool.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public WorkerPool.Builder toBuilder()
Returns
TypeDescription
WorkerPool.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException