be-technical-interview-rust/CHANGES.md

1.2 KiB

Backend internal interview (rust)

CHANGES: improved branch

  • Create abstractions / models to load and parse metrics, can be easily extended
  • Define basic operations via [MetricParser] trait path defs/metrics.rs
  • Use structs to group metrics attributes and implement operations like [metrics_consumer::MetricsConsumerTarget]
  • Use enums with associated values like [defs::metric_data::MetricsConsumerData] path defs/metric_data to group attributes and values
  • Remove Maps collections, use Vectors
  • Use const for DEFAULT values on [defs] module
  • Remove all hardcoded values to [Config] settings, a TOML config file (see config.toml) can be used to define several metrics input and customize output
  • Output write to file (append o rewrite mode) is working (for now I/O is sync)
  • Command line arguments are processed [parse_args] with [defs::CliSettings] via clap and overide the ones loaded in config files
  • Tests have been accommodated from previous Branch basic-fixed version to imporved approach