Class ConfigFile

java.lang.Object
org.apache.hadoop.yarn.service.api.records.ConfigFile
All Implemented Interfaces:
Serializable

@Public @Unstable public class ConfigFile extends Object implements Serializable
A config file that needs to be created and made available as a volume in an service component container.
See Also:
  • Constructor Details

    • ConfigFile

      public ConfigFile()
  • Method Details

    • copy

      public ConfigFile copy()
    • type

      public ConfigFile type(ConfigFile.TypeEnum type)
      Config file in the standard format like xml, properties, json, yaml, template.
    • getType

      public ConfigFile.TypeEnum getType()
    • setType

      public void setType(ConfigFile.TypeEnum type)
    • destFile

      public ConfigFile destFile(String destFile)
      The absolute path that this configuration file should be mounted as, in the service container.
    • getDestFile

      public String getDestFile()
    • setDestFile

      public void setDestFile(String destFile)
    • srcFile

      public ConfigFile srcFile(String srcFile)
      This provides the source location of the configuration file, the content of which is dumped to dest_file post property substitutions, in the format as specified in type. Typically the src_file would point to a source controlled network accessible file maintained by tools like puppet, chef, or hdfs etc. Currently, only hdfs is supported.
    • getSrcFile

      public String getSrcFile()
    • setSrcFile

      public void setSrcFile(String srcFile)
    • visibility

      public ConfigFile visibility(org.apache.hadoop.yarn.api.records.LocalResourceVisibility localrsrcVisibility)
      Visibility of the Config file.
    • getVisibility

      public org.apache.hadoop.yarn.api.records.LocalResourceVisibility getVisibility()
    • setVisibility

      public void setVisibility(org.apache.hadoop.yarn.api.records.LocalResourceVisibility localrsrcVisibility)
    • properties

      public ConfigFile properties(Map<String,String> properties)
      A blob of key value pairs that will be dumped in the dest_file in the format as specified in type. If src_file is specified, src_file content are dumped in the dest_file and these properties will overwrite, if any, existing properties in src_file or be added as new properties in src_file.
    • getProperties

      public Map<String,String> getProperties()
    • setProperties

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

      public long getLong(String name, long defaultValue)
    • getBoolean

      public boolean getBoolean(String name, boolean defaultValue)
    • 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