ContainerConfigReader

Helper class that reads a container’s configuration from a JSON or YAML file.

Description

The ContainerConfigReader class allows you to read a container’s configuration from a JSON or YAML file.

Static methods

read_from_file

Reads a container’s configuration from JSON or YAML file. The type of the file is determined by the file extension.

static read_from_file(correlation_id: Optional[str], path: str, parameters: ConfigParams): ContainerConfig

  • correlation_id: Optional[str] - (optional) transaction id used to trace execution through the call chain.
  • path: str - path to the component’s configuration file.
  • parameters: ConfigParams - configuration parameters or None to skip parameterization.
  • returns: ContainerConfig - read container configuration

read_from_json_file

Reads a container’s configuration from a JSON file.

static read_from_json_file(correlation_id: Optional[str], path: str, parameters: ConfigParams): ContainerConfig

  • correlation_id: Optional[str] - (optional) transaction id used to trace execution through the call chain.
  • path: str - path to the component’s configuration file.
  • parameters: ConfigParams - configuration parameters or None to skip parameterization.
  • returns: ContainerConfig - read container configuration

read_from_yalm_file

Reads container configuration from a YAML file.

static read_from_yaml_file(correlation_id: Optional[str], path: str, parameters: ConfigParams): ContainerConfig

  • correlation_id: Optional[str] - (optional) transaction id used to trace execution through the call chain.
  • path: str - path to the component’s configuration file.
  • parameters: ConfigParams - configuration parameters or None to skip parameterization.
  • returns: ContainerConfig - read container configuration