public static final class Protos.KillPolicy.Builder extends <any> implements Protos.KillPolicyOrBuilder
Describes a kill policy for a task. Currently does not express different policies (e.g. hitting HTTP endpoints), only controls how long to wait between graceful and forcible task kill: graceful kill --------------> forcible kill grace_period Kill policies are best-effort, because machine failures / forcible terminations may occur. NOTE: For executor-less command-based tasks, the kill is performed via sending a signal to the task process: SIGTERM for the graceful kill and SIGKILL for the forcible kill. For the docker executor-less tasks the grace period is passed to 'docker stop --time'.Protobuf type
mesos.KillPolicy
Modifier and Type | Method and Description |
---|---|
Protos.KillPolicy.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) |
Protos.KillPolicy |
build() |
Protos.KillPolicy |
buildPartial() |
Protos.KillPolicy.Builder |
clear() |
Protos.KillPolicy.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
Protos.KillPolicy.Builder |
clearGracePeriod()
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.KillPolicy.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
Protos.KillPolicy.Builder |
clone() |
Protos.KillPolicy |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
Protos.DurationInfo |
getGracePeriod()
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.DurationInfo.Builder |
getGracePeriodBuilder()
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.DurationInfoOrBuilder |
getGracePeriodOrBuilder()
The grace period specifies how long to wait before forcibly
killing the task.
|
boolean |
hasGracePeriod()
The grace period specifies how long to wait before forcibly
killing the task.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
Protos.KillPolicy.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
Protos.KillPolicy.Builder |
mergeFrom(com.google.protobuf.Message other) |
Protos.KillPolicy.Builder |
mergeGracePeriod(Protos.DurationInfo value)
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.KillPolicy.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
Protos.KillPolicy.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) |
Protos.KillPolicy.Builder |
setGracePeriod(Protos.DurationInfo.Builder builderForValue)
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.KillPolicy.Builder |
setGracePeriod(Protos.DurationInfo value)
The grace period specifies how long to wait before forcibly
killing the task.
|
Protos.KillPolicy.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
java.lang.Object value) |
Protos.KillPolicy.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
public Protos.KillPolicy.Builder clear()
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
public Protos.KillPolicy getDefaultInstanceForType()
public Protos.KillPolicy build()
public Protos.KillPolicy buildPartial()
public Protos.KillPolicy.Builder clone()
public Protos.KillPolicy.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
public Protos.KillPolicy.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
public Protos.KillPolicy.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
public Protos.KillPolicy.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)
public Protos.KillPolicy.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
public Protos.KillPolicy.Builder mergeFrom(com.google.protobuf.Message other)
public final boolean isInitialized()
public Protos.KillPolicy.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public boolean hasGracePeriod()
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
hasGracePeriod
in interface Protos.KillPolicyOrBuilder
public Protos.DurationInfo getGracePeriod()
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
getGracePeriod
in interface Protos.KillPolicyOrBuilder
public Protos.KillPolicy.Builder setGracePeriod(Protos.DurationInfo value)
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
public Protos.KillPolicy.Builder setGracePeriod(Protos.DurationInfo.Builder builderForValue)
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
public Protos.KillPolicy.Builder mergeGracePeriod(Protos.DurationInfo value)
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
public Protos.KillPolicy.Builder clearGracePeriod()
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
public Protos.DurationInfo.Builder getGracePeriodBuilder()
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
public Protos.DurationInfoOrBuilder getGracePeriodOrBuilder()
The grace period specifies how long to wait before forcibly killing the task. It is recommended to attempt to gracefully kill the task (and send TASK_KILLING) to indicate that the graceful kill is in progress. Once the grace period elapses, if the task has not terminated, a forcible kill should occur. The task should not assume that it will always be allotted the full grace period. For example, the executor may be shutdown more quickly by the agent, or failures / forcible terminations may occur.
optional .mesos.DurationInfo grace_period = 1;
getGracePeriodOrBuilder
in interface Protos.KillPolicyOrBuilder
public final Protos.KillPolicy.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
public final Protos.KillPolicy.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)