Class V1.Lifecycle.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
io.kubernetes.client.proto.V1.Lifecycle.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, V1.LifecycleOrBuilder, Cloneable
Enclosing class:
V1.Lifecycle

public static final class V1.Lifecycle.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder> implements V1.LifecycleOrBuilder
 Lifecycle describes actions that the management system should take in response to container lifecycle
 events. For the PostStart and PreStop lifecycle handlers, management of the container blocks
 until the action is complete, unless the container process fails, in which case the handler is aborted.
 
Protobuf type k8s.io.api.core.v1.Lifecycle
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • clear

      public V1.Lifecycle.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • getDefaultInstanceForType

      public V1.Lifecycle getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public V1.Lifecycle build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public V1.Lifecycle buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • clone

      public V1.Lifecycle.Builder clone()
      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • setField

      public V1.Lifecycle.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • clearField

      public V1.Lifecycle.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • clearOneof

      public V1.Lifecycle.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • setRepeatedField

      public V1.Lifecycle.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • addRepeatedField

      public V1.Lifecycle.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • mergeFrom

      public V1.Lifecycle.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<V1.Lifecycle.Builder>
    • mergeFrom

      public V1.Lifecycle.Builder mergeFrom(V1.Lifecycle other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • mergeFrom

      public V1.Lifecycle.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<V1.Lifecycle.Builder>
      Throws:
      IOException
    • hasPostStart

      public boolean hasPostStart()
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
      Specified by:
      hasPostStart in interface V1.LifecycleOrBuilder
    • getPostStart

      public V1.LifecycleHandler getPostStart()
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
      Specified by:
      getPostStart in interface V1.LifecycleOrBuilder
    • setPostStart

      public V1.Lifecycle.Builder setPostStart(V1.LifecycleHandler value)
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
    • setPostStart

      public V1.Lifecycle.Builder setPostStart(V1.LifecycleHandler.Builder builderForValue)
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
    • mergePostStart

      public V1.Lifecycle.Builder mergePostStart(V1.LifecycleHandler value)
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
    • clearPostStart

      public V1.Lifecycle.Builder clearPostStart()
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
    • getPostStartBuilder

      public V1.LifecycleHandler.Builder getPostStartBuilder()
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
    • getPostStartOrBuilder

      public V1.LifecycleHandlerOrBuilder getPostStartOrBuilder()
       PostStart is called immediately after a container is created. If the handler fails,
       the container is terminated and restarted according to its restart policy.
       Other management of the container blocks until the hook completes.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler postStart = 1;
      Specified by:
      getPostStartOrBuilder in interface V1.LifecycleOrBuilder
    • hasPreStop

      public boolean hasPreStop()
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
      Specified by:
      hasPreStop in interface V1.LifecycleOrBuilder
    • getPreStop

      public V1.LifecycleHandler getPreStop()
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
      Specified by:
      getPreStop in interface V1.LifecycleOrBuilder
    • setPreStop

      public V1.Lifecycle.Builder setPreStop(V1.LifecycleHandler value)
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
    • setPreStop

      public V1.Lifecycle.Builder setPreStop(V1.LifecycleHandler.Builder builderForValue)
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
    • mergePreStop

      public V1.Lifecycle.Builder mergePreStop(V1.LifecycleHandler value)
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
    • clearPreStop

      public V1.Lifecycle.Builder clearPreStop()
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
    • getPreStopBuilder

      public V1.LifecycleHandler.Builder getPreStopBuilder()
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
    • getPreStopOrBuilder

      public V1.LifecycleHandlerOrBuilder getPreStopOrBuilder()
       PreStop is called immediately before a container is terminated due to an
       API request or management event such as liveness/startup probe failure,
       preemption, resource contention, etc. The handler is not called if the
       container crashes or exits. The reason for termination is passed to the
       handler. The Pod's termination grace period countdown begins before the
       PreStop hooked is executed. Regardless of the outcome of the handler, the
       container will eventually terminate within the Pod's termination grace
       period. Other management of the container blocks until the hook completes
       or until the termination grace period is reached.
       More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
       +optional
       
      optional .k8s.io.api.core.v1.LifecycleHandler preStop = 2;
      Specified by:
      getPreStopOrBuilder in interface V1.LifecycleOrBuilder
    • setUnknownFields

      public final V1.Lifecycle.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>
    • mergeUnknownFields

      public final V1.Lifecycle.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<V1.Lifecycle.Builder>