send :: HostName -> PortNumber -> Socket -> SockAddr -> IO BlockData -> IO () -- TODO ByteString
send host port sock addr getMsgsToSendToConsensusNodes = do
  infoN host port "send: waiting"
  msg <- getMsgsToSendToConsensusNodes
  infoN host port ("send: " ++ show msg)
  sendTo sock msg addr
  send host port sock addr getMsgsToSendToConsensusNodes
send :: HostName -> PortNumber -> Socket -> SockAddr -> IO BlockData -> IO ()
send host port sock addr getMsgsToSendToConsensusNodes = do
  infoN host port "send: waiting"
  msg <- getMsgsToSendToConsensusNodes
  infoN host port ("send: " ++ show msg)
  sendTo sock msg addr
  send host port sock addr getMsgsToSendToConsensusNodes
send host port sock addr getMsgsToSendToConsensusNodes = do
  infoN host port "send: waiting"
  msg <- getMsgsToSendToConsensusNodes
  infoN host port ("send: " ++ show msg)
  sendTo sock msg addr
  send host port sock addr getMsgsToSendToConsensusNodes