Quantcast
Channel: StackExchange Replication Questions
Viewing all articles
Browse latest Browse all 17268

boost::asio and short messages: low latency how to make it?

$
0
0

Part of master-slave replication protocol:

  1. Master sends append data to slaves
  2. After got reply from slaves, Master needs to send COMMIT to slaves and wait for commit done

boost::asio is tried for #2 step, using sync write and read. Master write a short commit message to slaves, and slaves read and write a reply. After master receives majority of the replies, commit is done and send OK to client.

The goal is to make the #2 step as fast as it can be. The message are short and I want the latency low and requests per second high. Any advice on how to achieve this?


Viewing all articles
Browse latest Browse all 17268

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>