Skip to content

Allow teams to connect faster

Hannes Braun requested to merge hannesbraun/rclm2:speedup-spark-start into master

If SimSpark!22 (merged) gets merged, the league manager should be adjusted to not wait 20 seconds between joining the teams. I chose 5 seconds for this, but this might depend on the system the server and clients are running on.

The reason why we still need to wait between joining teams is to not flip the sides of the team. If we would remove that sleep command, the second team may connect one of its agents before the first team. Since the server also needs two or three seconds when the first agent connects, this contributes to the problem of having flipped sides for the teams.

An alternative for calling the sleep command could be to write a simple small program (probably in C) that connects to the server (as a monitor) and returns as soon as it finds the string "team_left" in the monitor output (indicating that the left team joined). What do you think? Would that additional safety be worth it or can we further rely on the sleep?

Merge request reports