ReadinessCheck (Apache Hadoop Main 3.5.0 API)
Description: declaration: package: org.apache.hadoop.yarn.service.api.records, class: ReadinessCheck

Package org.apache.hadoop.yarn.service.api.records

# Class ReadinessCheck

java.lang.Object
org.apache.hadoop.yarn.service.api.records.ReadinessCheck

All Implemented Interfaces:
  `Serializable`

@Public @Unstable public class ReadinessCheck extends Object implements Serializable
A custom command or a pluggable helper container to determine the readiness of a container of a component. Readiness for every service is different. Hence the need for a simple interface, with scope to support advanced usecases.

See Also:
  - Serialized Form

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static enum`
  `ReadinessCheck.TypeEnum`
  Type.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ReadinessCheck()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `ReadinessCheck`
  `artifact(Artifact artifact)`
  Artifact of the pluggable readiness check helper container (optional).
  `boolean`
  `equals(Object o)`
  `Artifact`
  `getArtifact()`
  `Map<String,String>`
  `getProperties()`
  A blob of key value pairs that will be used to configure the check.
  `ReadinessCheck.TypeEnum`
  `getType()`
  `int`
  `hashCode()`
  `ReadinessCheck`
  `properties(Map<String,String> properties)`
  `ReadinessCheck`
  `putPropsItem(String key, String propsItem)`
  `void`
  `setArtifact(Artifact artifact)`
  `void`
  `setProperties(Map<String,String> properties)`
  `void`
  `setType(ReadinessCheck.TypeEnum type)`
  `String`
  `toString()`
  `ReadinessCheck`
  `type(ReadinessCheck.TypeEnum type)`
  E.g.

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### ReadinessCheck

    public ReadinessCheck()

- ## Method Details

  - ### type

    public ReadinessCheck type(ReadinessCheck.TypeEnum type)
    E.g. HTTP (YARN will perform a simple REST call at a regular interval and expect a 204 No content).

  - ### getType

    public ReadinessCheck.TypeEnum getType()

  - ### setType

    public void setType(ReadinessCheck.TypeEnum type)

  - ### properties

    public ReadinessCheck properties(Map<String,String> properties)

  - ### putPropsItem

    public ReadinessCheck putPropsItem(String key, String propsItem)

  - ### getProperties

    public Map<String,String> getProperties()
    A blob of key value pairs that will be used to configure the check.
    Returns:
      properties

  - ### setProperties

    public void setProperties(Map<String,String> properties)

  - ### artifact

    public ReadinessCheck artifact(Artifact artifact)
    Artifact of the pluggable readiness check helper container (optional). If specified, this helper container typically hosts the http uri and encapsulates the complex scripts required to perform actual container readiness check. At the end it is expected to respond a 204 No content just like the simplified use case. This pluggable framework benefits service owners who can run services without any packaging modifications. Note, artifacts of type docker only is supported for now.

  - ### getArtifact

    public Artifact getArtifact()

  - ### setArtifact

    public void setArtifact(Artifact artifact)

  - ### equals

    public boolean equals(Object o)
    Overrides:
      `equals` in class `Object`

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `Object`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`