Resolve "Duniter is using 100% of one CPU core"
Closes #297 (closed)
The issue was that command_rx was always ready, even if it did not have received any command. As a consequence, the running async loop was heavily triggered causing high CPU usage.
Furthermore it always took precedence over handle_notification_event's future, which explains why peering documents were not shared.
@bgallois already noticed about a potential issue with
command_rxwhich is only used for tests for now.
This MR also adds more logs.
Edited by Cédric Moreau