- Start by installing all necessary dependencies. To do so, run the following command on the root directory (HDL)
mvn clean install -DskipTests
- After that, compile the project code. To do so, run the following command on the root directory (HDL):
mvn clean compile
- Then, simply spawn the desired number of processes following these instructions:
-
To spawn a Client process:
- On the
Client
directory, execute the following command:mvn exec:java -Dmainclass=sec.G31.client -Dexec.args="<client_id> <client_address> <client_port> <config_file>"
- On the
-
To spawn a Server process:
- On the
Server
directory, execute the following command:mvn exec:java -Dmainclass=sec.G31 -Dexec.args="<server_id> <server_addres> <server_port> <fault_type> <leader_flag> <F> <config_file>"
- where '<fault_type>' is either
F
(for byzantine processes) orNF
(for correct processes), '<leader_flag>' is eitherY
(if process is the leader) orN
(otherwise), and '< F >' is the maximum number of byzantine processes tolerated (i.e. if F is set to 1, at least 3 correct processes are required in order for the system to work).
- On the
- Build the project following the first two steps mentioned in the above section
- Run the command
mvn test
in theClient
directory. This will run all unit tests. In order to run a particular test use the commandmvn test -Dtest=AppClientTest#<test-name>
, where '<test_name>' is the name of the specific test you want to execute.