dqian3 / DOM-BFT

MIT License
0 stars 0 forks source link

Configuration overhaul/scripts #1

Closed dqian3 closed 3 weeks ago

dqian3 commented 4 months ago

Currently the configuration of each process is done using separate YAML files. These need to be created manually, along with the parsers into C++ objects which are kind of easy to mess up and a lot of duplicated work.

There are a few ideas to rectify this, not necessarily mutually exclusive.

  1. Write some scripts that transform a central configuration (i.e. list of machines + high level settings) into individual YAML configurations for each process (i.e. proxy, replica, client).
  2. Make a general YAML object parser for process configuration

Feel free to discuss below.

dqian3 commented 3 months ago

A third idea would just be a single (yaml) file. This might be the best option

This removes redundant information such as

Processes compute their configuration by knowing what they are (i.e. client, replica or proxy) and command line arguments for their ids. For example, a replica would choose their IP from a list of the replica IPs. The replica would also choose its private key file from a list of private keys

Furthermore, some configurations are global and require a few tweaks. For example, the choice to use IPC for the receiver vs IP. Such global changes could be easy to mess up or have inconsistencies.

This single file can also drive deployment scripts, since we know what machines to call

We should probably add better checking and error handling