public final class Runnable extends com.google.protobuf.GeneratedMessageV3 implements RunnableOrBuilder
Runnable describes instructions for executing a specific script or container as part of a Task.Protobuf type
google.cloud.batch.v1.Runnable| Modifier and Type | Class and Description |
|---|---|
static class |
Runnable.Barrier
A barrier runnable automatically blocks the execution of subsequent
runnables until all the tasks in the task group reach the barrier.
|
static interface |
Runnable.BarrierOrBuilder |
static class |
Runnable.Builder
Runnable describes instructions for executing a specific script or container
as part of a Task.
|
static class |
Runnable.Container
Container runnable.
|
static interface |
Runnable.ContainerOrBuilder |
static class |
Runnable.ExecutableCase |
static class |
Runnable.Script
Script runnable.
|
static interface |
Runnable.ScriptOrBuilder |
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
ALWAYS_RUN_FIELD_NUMBER |
static int |
BACKGROUND_FIELD_NUMBER |
static int |
BARRIER_FIELD_NUMBER |
static int |
CONTAINER_FIELD_NUMBER |
static int |
DISPLAY_NAME_FIELD_NUMBER |
static int |
ENVIRONMENT_FIELD_NUMBER |
static int |
IGNORE_EXIT_STATUS_FIELD_NUMBER |
static int |
LABELS_FIELD_NUMBER |
static int |
SCRIPT_FIELD_NUMBER |
static int |
TIMEOUT_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsLabels(String key)
Labels for this Runnable.
|
boolean |
equals(Object obj) |
boolean |
getAlwaysRun()
By default, after a Runnable fails, no further Runnable are executed.
|
boolean |
getBackground()
Normally, a runnable that doesn't exit causes its task to fail.
|
Runnable.Barrier |
getBarrier()
Barrier runnable.
|
Runnable.BarrierOrBuilder |
getBarrierOrBuilder()
Barrier runnable.
|
Runnable.Container |
getContainer()
Container runnable.
|
Runnable.ContainerOrBuilder |
getContainerOrBuilder()
Container runnable.
|
static Runnable |
getDefaultInstance() |
Runnable |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
String |
getDisplayName()
Optional.
|
com.google.protobuf.ByteString |
getDisplayNameBytes()
Optional.
|
Environment |
getEnvironment()
Environment variables for this Runnable (overrides variables set for the
whole Task or TaskGroup).
|
EnvironmentOrBuilder |
getEnvironmentOrBuilder()
Environment variables for this Runnable (overrides variables set for the
whole Task or TaskGroup).
|
Runnable.ExecutableCase |
getExecutableCase() |
boolean |
getIgnoreExitStatus()
Normally, a runnable that returns a non-zero exit status fails and causes
the task to fail.
|
Map<String,String> |
getLabels()
Deprecated.
|
int |
getLabelsCount()
Labels for this Runnable.
|
Map<String,String> |
getLabelsMap()
Labels for this Runnable.
|
String |
getLabelsOrDefault(String key,
String defaultValue)
Labels for this Runnable.
|
String |
getLabelsOrThrow(String key)
Labels for this Runnable.
|
com.google.protobuf.Parser<Runnable> |
getParserForType() |
Runnable.Script |
getScript()
Script runnable.
|
Runnable.ScriptOrBuilder |
getScriptOrBuilder()
Script runnable.
|
int |
getSerializedSize() |
com.google.protobuf.Duration |
getTimeout()
Timeout for this Runnable.
|
com.google.protobuf.DurationOrBuilder |
getTimeoutOrBuilder()
Timeout for this Runnable.
|
boolean |
hasBarrier()
Barrier runnable.
|
boolean |
hasContainer()
Container runnable.
|
boolean |
hasEnvironment()
Environment variables for this Runnable (overrides variables set for the
whole Task or TaskGroup).
|
int |
hashCode() |
boolean |
hasScript()
Script runnable.
|
boolean |
hasTimeout()
Timeout for this Runnable.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
protected com.google.protobuf.MapFieldReflectionAccessor |
internalGetMapFieldReflection(int number) |
boolean |
isInitialized() |
static Runnable.Builder |
newBuilder() |
static Runnable.Builder |
newBuilder(Runnable prototype) |
Runnable.Builder |
newBuilderForType() |
protected Runnable.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static Runnable |
parseDelimitedFrom(InputStream input) |
static Runnable |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Runnable |
parseFrom(byte[] data) |
static Runnable |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Runnable |
parseFrom(ByteBuffer data) |
static Runnable |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Runnable |
parseFrom(com.google.protobuf.ByteString data) |
static Runnable |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Runnable |
parseFrom(com.google.protobuf.CodedInputStream input) |
static Runnable |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Runnable |
parseFrom(InputStream input) |
static Runnable |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<Runnable> |
parser() |
Runnable.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int CONTAINER_FIELD_NUMBER
public static final int SCRIPT_FIELD_NUMBER
public static final int BARRIER_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
public static final int IGNORE_EXIT_STATUS_FIELD_NUMBER
public static final int BACKGROUND_FIELD_NUMBER
public static final int ALWAYS_RUN_FIELD_NUMBER
public static final int ENVIRONMENT_FIELD_NUMBER
public static final int TIMEOUT_FIELD_NUMBER
public static final int LABELS_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessageV3protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public Runnable.ExecutableCase getExecutableCase()
getExecutableCase in interface RunnableOrBuilderpublic boolean hasContainer()
Container runnable.
.google.cloud.batch.v1.Runnable.Container container = 1;hasContainer in interface RunnableOrBuilderpublic Runnable.Container getContainer()
Container runnable.
.google.cloud.batch.v1.Runnable.Container container = 1;getContainer in interface RunnableOrBuilderpublic Runnable.ContainerOrBuilder getContainerOrBuilder()
Container runnable.
.google.cloud.batch.v1.Runnable.Container container = 1;getContainerOrBuilder in interface RunnableOrBuilderpublic boolean hasScript()
Script runnable.
.google.cloud.batch.v1.Runnable.Script script = 2;hasScript in interface RunnableOrBuilderpublic Runnable.Script getScript()
Script runnable.
.google.cloud.batch.v1.Runnable.Script script = 2;getScript in interface RunnableOrBuilderpublic Runnable.ScriptOrBuilder getScriptOrBuilder()
Script runnable.
.google.cloud.batch.v1.Runnable.Script script = 2;getScriptOrBuilder in interface RunnableOrBuilderpublic boolean hasBarrier()
Barrier runnable.
.google.cloud.batch.v1.Runnable.Barrier barrier = 6;hasBarrier in interface RunnableOrBuilderpublic Runnable.Barrier getBarrier()
Barrier runnable.
.google.cloud.batch.v1.Runnable.Barrier barrier = 6;getBarrier in interface RunnableOrBuilderpublic Runnable.BarrierOrBuilder getBarrierOrBuilder()
Barrier runnable.
.google.cloud.batch.v1.Runnable.Barrier barrier = 6;getBarrierOrBuilder in interface RunnableOrBuilderpublic String getDisplayName()
Optional. DisplayName is an optional field that can be provided by the caller. If provided, it will be used in logs and other outputs to identify the script, making it easier for users to understand the logs. If not provided the index of the runnable will be used for outputs.
string display_name = 10 [(.google.api.field_behavior) = OPTIONAL];getDisplayName in interface RunnableOrBuilderpublic com.google.protobuf.ByteString getDisplayNameBytes()
Optional. DisplayName is an optional field that can be provided by the caller. If provided, it will be used in logs and other outputs to identify the script, making it easier for users to understand the logs. If not provided the index of the runnable will be used for outputs.
string display_name = 10 [(.google.api.field_behavior) = OPTIONAL];getDisplayNameBytes in interface RunnableOrBuilderpublic boolean getIgnoreExitStatus()
Normally, a runnable that returns a non-zero exit status fails and causes the task to fail. However, you can set this field to `true` to allow the task to continue executing its other runnables even if this runnable fails.
bool ignore_exit_status = 3;getIgnoreExitStatus in interface RunnableOrBuilderpublic boolean getBackground()
Normally, a runnable that doesn't exit causes its task to fail. However, you can set this field to `true` to configure a background runnable. Background runnables are allowed continue running in the background while the task executes subsequent runnables. For example, background runnables are useful for providing services to other runnables or providing debugging-support tools like SSH servers. Specifically, background runnables are killed automatically (if they have not already exited) a short time after all foreground runnables have completed. Even though this is likely to result in a non-zero exit status for the background runnable, these automatic kills are not treated as task failures.
bool background = 4;getBackground in interface RunnableOrBuilderpublic boolean getAlwaysRun()
By default, after a Runnable fails, no further Runnable are executed. This flag indicates that this Runnable must be run even if the Task has already failed. This is useful for Runnables that copy output files off of the VM or for debugging. The always_run flag does not override the Task's overall max_run_duration. If the max_run_duration has expired then no further Runnables will execute, not even always_run Runnables.
bool always_run = 5;getAlwaysRun in interface RunnableOrBuilderpublic boolean hasEnvironment()
Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup).
.google.cloud.batch.v1.Environment environment = 7;hasEnvironment in interface RunnableOrBuilderpublic Environment getEnvironment()
Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup).
.google.cloud.batch.v1.Environment environment = 7;getEnvironment in interface RunnableOrBuilderpublic EnvironmentOrBuilder getEnvironmentOrBuilder()
Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup).
.google.cloud.batch.v1.Environment environment = 7;getEnvironmentOrBuilder in interface RunnableOrBuilderpublic boolean hasTimeout()
Timeout for this Runnable.
.google.protobuf.Duration timeout = 8;hasTimeout in interface RunnableOrBuilderpublic com.google.protobuf.Duration getTimeout()
Timeout for this Runnable.
.google.protobuf.Duration timeout = 8;getTimeout in interface RunnableOrBuilderpublic com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder()
Timeout for this Runnable.
.google.protobuf.Duration timeout = 8;getTimeoutOrBuilder in interface RunnableOrBuilderpublic int getLabelsCount()
RunnableOrBuilderLabels for this Runnable.
map<string, string> labels = 9;getLabelsCount in interface RunnableOrBuilderpublic boolean containsLabels(String key)
Labels for this Runnable.
map<string, string> labels = 9;containsLabels in interface RunnableOrBuilder@Deprecated public Map<String,String> getLabels()
getLabelsMap() instead.getLabels in interface RunnableOrBuilderpublic Map<String,String> getLabelsMap()
Labels for this Runnable.
map<string, string> labels = 9;getLabelsMap in interface RunnableOrBuilderpublic String getLabelsOrDefault(String key, String defaultValue)
Labels for this Runnable.
map<string, string> labels = 9;getLabelsOrDefault in interface RunnableOrBuilderpublic String getLabelsOrThrow(String key)
Labels for this Runnable.
map<string, string> labels = 9;getLabelsOrThrow in interface RunnableOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static Runnable parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Runnable parseFrom(InputStream input) throws IOException
IOExceptionpublic static Runnable parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Runnable parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static Runnable parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Runnable parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static Runnable parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic Runnable.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static Runnable.Builder newBuilder()
public static Runnable.Builder newBuilder(Runnable prototype)
public Runnable.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected Runnable.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static Runnable getDefaultInstance()
public static com.google.protobuf.Parser<Runnable> parser()
public com.google.protobuf.Parser<Runnable> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public Runnable getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2025 Google LLC. All rights reserved.