  The fast increment in the number of IoT (Internet of Things) devices is
accelerating the research on new solutions to make cloud services scalable. In
this context, the novel concept of fog computing as well as the combined
fog-to-cloud computing paradigm is becoming essential to decentralize the
cloud, while bringing the services closer to the end-system. This paper surveys
on the application layer communication protocols to fulfil the IoT
communication requirements, and their potential for implementation in fog- and
cloud-based IoT systems. To this end, the paper first presents a comparative
analysis of the main characteristics of IoT communication protocols, including
request-reply and publish-subscribe protocols. After that, the paper surveys
the protocols that are widely adopted and implemented in each segment of the
system (IoT, fog, cloud), and thus opens up the discussion on their
interoperability and wider system integration. Finally, the paper reviews the
main performance issues, including latency, energy consumption and network
throughput. The survey is expected to be useful to system architects and
protocol designers when choosing the communication protocols in an integrated
IoT-to-fog-to-cloud system architecture.
