透過您的圖書館登入
IP:3.129.211.87
  • 學位論文

應用於物聯網環境之階層式發布/訂閱架構實作

Implementation of Hierarchical Publish/Subscribe Architecture for IoT Environment

指導教授 : 林其誼
共同指導教授 : 許輝煌(Hui-huang Hsu)

摘要


P2P(Peer-to-Peer),又稱點對點傳輸,是一種網路架構。在P2P的運作模式中,相對於傳統的主從式架構(Client-Server),每個端點(Client)的溝通都會透過伺服器來傳遞。因此,在上述的環境中,每一個客戶端都是分散的。每一個端點都可以作為客戶端或伺服器端,甚至是同時兼任兩者而存在著。 近年來,由於物聯網的興起,另一種名為發布/訂閱(Publish/Subscribe)的通訊架構也逐漸流行。它的特色是由一個中間者(Broker)擔任伺服器,接收來自於發布者(Publisher)所發布的主題訊息,再轉發給訂閱該主題的訂閱者(Subscriber)。這麼做最大的好處在於可減少訊息發布者與訂閱者之間在時間與空間中的耦合,兩者甚至都不需要知道對方的存在。但是,萬一中間者發生故障,訊息遞送服務就無法運作。 為了解決 Pub/Sub 架構中的單點故障(SPOF)的問題,在本篇論文中,我們基於開源軟體 ActiveMQ 實現了階層式中間者的架構。具體來說,我們在具有 Raspberry Pi 開發版的 IoT 環境中部署兩層的中間者群集。數據在上層中間者(又稱中間者中心)之間進行同步,並在雙活躍配置下運行,為發布者提供服務。下層中間者(又稱中間者)由中間者中心管理,並負責為訂閱者提供服務。我們進行了幾次實驗,以測試階層式中間者架構的容錯能力,以及評估與單個中間者相比之下階層式中間者架構的系統性能。

並列摘要


P2P, or Peer-to-Peer, is a decentralized network architecture. Compared with the traditional Client-Server architecture, in P2P model each peer can communicate with each other directly without the need of a centralized server. Specifically, each peer can play the role of a client or a server, or even play the two roles simultaneously. In recent years, a new network architecture called Publish/Subscribe (Pub/Sub) is getting popular due to the prevalence of IoT. The unique feature of the Pub/Sub architecture is that a broker plays the role of a server, which receives messages with a specific topic published by the publishers, and then forwards the messages to the subscribers who previously subscribed the topic. This can decouple the publishers and the subscribers both in time and space. They don't even need to be aware of the existence of each other. However, once the broker fails, the message delivery service also fails. To solve the single point of failure (SPOF) problem of the Pub/Sub model, in this thesis we implement the hierarchical broker architecture based on ActiveMQ, an open source software. Specifically, we deploy a two-layer broker cluster in an IoT environment with Raspberry Pi 3 development boards. The data is synchronized between the upper-layer brokers (called Broker Hubs), and they run in a dual-active configuration to serve the publishers. The lower-layer brokers (just called Brokers) are managed by the broker hubs, and are responsible for serving the subscribers. We conducted several experiments to test the fault tolerance capability of the hierarchical broker architecture, as well as evaluating the system performance of the hierarchical broker architecture compared with a single broker.

並列關鍵字

Pub/Sub Open source software ActiveMQ JMS Hierarchical Broker

參考文獻


[1] DAI Jun,ZHU Xiao-Min.Design and Implementation of an Asynchronous Message Bus Based on ActiveMQ.COMPUTER SYSTEMS APPLICATIONS,2010,19(8):254-257
[2] H. Chien, G. Qiu, R. Hung, A. Shih and C. Su, "Hierarchical MQTT with Edge Computation," 2019 IEEE 10th International Conference on Awareness Science and Technology (iCAST), Morioka, Japan, 2019, pp. 1-5
[3] http://puremonkey2010.blogspot.com/2015/09/inaction-note-ch4-connecting-activemq.html, last accessed Jun. 30, 2020
[4] https://www.jakubkorab.net/2011/11/understanding-activemq-broker-networks.html, last accessed Jun. 30, 2020
[5] https://www.itread01.com/articles/1488744004.htm, last accessed Jun. 30, 2020

延伸閱讀