Skip to main content

parse_configurations

Function parse_configurations 

Source
pub fn parse_configurations(
    conf_file: &str,
    worker_map: &BiHashMap<u32, String>,
) -> Vec<Configuration>
Expand description

Parse the worker configurations from a file.

§Arguments

  • conf_file - path to the configuration file
  • worker_map - a BiHashMap mapping worker IDs to hostnames

§Returns

  • A vector of Configuration objects parsed from the file

§Panics

  • If the configuration file cannot be opened.
  • If the configuration file contains invalid formats.
  • If no valid configurations are found in the file.