{"id":32888,"date":"2023-09-18T11:26:16","date_gmt":"2023-09-18T03:26:16","guid":{"rendered":"https:\/\/www.techphant.cn\/?p=32888"},"modified":"2023-09-18T11:26:16","modified_gmt":"2023-09-18T03:26:16","slug":"wsmmymcgq","status":"publish","type":"post","link":"https:\/\/www.techphant.cn\/blog\/32888.html","title":{"rendered":"\u4e3a\u4ec0\u4e48\u6ca1\u6709MQTT\u4f20\u611f\u5668\uff1f"},"content":{"rendered":"

  MQTT\u662f\u4e00\u79cd\u53ef\u4ee5\u7528\u6765\u4f20\u8f93\u6570\u636e\u7684\u534f\u8bae\uff0c\u5b83\u53ef\u4ee5\u66f4\u6709\u6548\u5730\u4f20\u8f93\u6570\u636e\uff0c\u6bd4\u4f20\u7edf\u7684HTTP\u534f\u8bae\u66f4\u6709\u6548\u7387\u3002\u4f46\u662f\uff0cMQTT\u4f20\u611f\u5668\u5728\u5e02\u573a\u4e0a\u5e76\u4e0d\u5e38\u89c1\uff0c\u6240\u4ee5\u6211\u4eec\u6765\u63a2\u7a76\u4e00\u4e0b\u4e3a\u4ec0\u4e48\u6ca1\u6709MQTT\u4f20\u611f\u5668\u3002<\/p>\n

MQTT\u534f\u8bae\u7684\u4f18\u52bf<\/h2>\n

1.\u4f4e\u5ef6\u8fdf<\/h3>\n

  MQTT\u534f\u8bae\u7684\u4e3b\u8981\u4f18\u52bf\u4e4b\u4e00\u662f\u5b83\u53ef\u4ee5\u63d0\u4f9b\u66f4\u4f4e\u7684\u5ef6\u8fdf\uff0c\u76f8\u6bd4HTTP\u534f\u8bae\uff0cMQTT\u534f\u8bae\u53ef\u4ee5\u63d0\u4f9b\u66f4\u4f4e\u7684\u5ef6\u8fdf\uff0c\u8fd9\u4f7f\u5f97\u5b83\u7279\u522b\u9002\u5408\u5b9e\u65f6\u5e94\u7528\u7a0b\u5e8f\u3002<\/p>\n

2.\u66f4\u5c0f\u7684\u6570\u636e\u5305<\/h3>\n

  \u53e6\u4e00\u4e2aMQTT\u534f\u8bae\u7684\u4f18\u52bf\u662f\u5b83\u53ef\u4ee5\u4f20\u8f93\u66f4\u5c0f\u7684\u6570\u636e\u5305\uff0c\u8fd9\u4f7f\u5f97\u5b83\u53ef\u4ee5\u66f4\u6709\u6548\u5730\u4f7f\u7528\u5e26\u5bbd\uff0c\u5e76\u4e14\u53ef\u4ee5\u66f4\u5feb\u5730\u4f20\u8f93\u6570\u636e\u3002<\/p>\n

3.\u9ad8\u53ef\u9760\u6027<\/h3>\n

  MQTT\u534f\u8bae\u8fd8\u5177\u6709\u9ad8\u53ef\u9760\u6027\uff0c\u5b83\u53ef\u4ee5\u786e\u4fdd\u6570\u636e\u7684\u53ef\u9760\u4f20\u8f93\uff0c\u8fd9\u5728\u5b9e\u65f6\u5e94\u7528\u7a0b\u5e8f\u4e2d\u5c24\u4e3a\u91cd\u8981\u3002<\/p>\n

\u4e3a\u4ec0\u4e48\u6ca1\u6709MQTT\u4f20\u611f\u5668\uff1f<\/h2>\n

1.\u6210\u672c\u95ee\u9898<\/h3>\n

  MQTT\u4f20\u611f\u5668\u7684\u4e3b\u8981\u95ee\u9898\u4e4b\u4e00\u662f\u6210\u672c\u95ee\u9898\uff0c\u7531\u4e8eMQTT\u534f\u8bae\u6bd4HTTP\u534f\u8bae\u66f4\u590d\u6742\uff0c\u6240\u4ee5MQTT\u4f20\u611f\u5668\u7684\u6210\u672c\u4e5f\u66f4\u9ad8\uff0c\u8fd9\u4f7f\u5f97MQTT\u4f20\u611f\u5668\u5728\u5e02\u573a\u4e0a\u4e0d\u592a\u53d7\u6b22\u8fce\u3002<\/p>\n

2.\u6280\u672f\u96be\u5ea6<\/h3>\n

  \u53e6\u4e00\u4e2a\u539f\u56e0\u662fMQTT\u4f20\u611f\u5668\u7684\u6280\u672f\u96be\u5ea6\u6bd4HTTP\u4f20\u611f\u5668\u8981\u9ad8\uff0c\u5b83\u9700\u8981\u66f4\u591a\u7684\u6280\u672f\u77e5\u8bc6\u6765\u5f00\u53d1\u548c\u7ef4\u62a4\uff0c\u8fd9\u4f7f\u5f97MQTT\u4f20\u611f\u5668\u4e0d\u592a\u5bb9\u6613\u88ab\u666e\u901a\u7528\u6237\u4f7f\u7528\u3002<\/p>\n

3.\u529f\u80fd\u95ee\u9898<\/h3>\n

  \u6700\u540e\uff0cMQTT\u4f20\u611f\u5668\u7684\u529f\u80fd\u4e5f\u6bd4HTTP\u4f20\u611f\u5668\u8981\u5c11\uff0c\u8fd9\u4f7f\u5f97\u5b83\u4e0d\u592a\u9002\u5408\u4e00\u4e9b\u7279\u5b9a\u7684\u5e94\u7528\u573a\u666f\uff0c\u6bd4\u5982\u5b9e\u65f6\u5e94\u7528\u7a0b\u5e8f\uff0c\u6240\u4ee5\u5b83\u5728\u5e02\u573a\u4e0a\u4e5f\u4e0d\u592a\u53d7\u6b22\u8fce\u3002<\/p>\n

\u603b\u7ed3<\/h2>\n

  \u4ece\u4e0a\u9762\u7684\u5206\u6790\u53ef\u4ee5\u770b\u51fa\uff0cMQTT\u4f20\u611f\u5668\u76f8\u6bd4HTTP\u4f20\u611f\u5668\u6709\u7740\u5f88\u591a\u4f18\u52bf\uff0c\u4f46\u662f\u7531\u4e8e\u6210\u672c\u3001\u6280\u672f\u96be\u5ea6\u548c\u529f\u80fd\u7684\u539f\u56e0\uff0cMQTT\u4f20\u611f\u5668\u5728\u5e02\u573a\u4e0a\u5e76\u4e0d\u5e38\u89c1\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

MQTT\u662f\u4e00\u79cd\u53ef\u4ee5\u7528\u6765\u4f20\u8f93\u6570\u636e\u7684\u534f\u8bae\uff0c\u5b83\u53ef\u4ee5\u66f4\u6709\u6548\u5730\u4f20\u8f93\u6570\u636e\uff0c\u6bd4\u4f20\u7edf\u7684HTTP\u534f\u8bae\u66f4\u6709\u6548\u7387\u3002\u4f46\u662f\uff0cMQTT\u4f20\u611f\u5668\u5728\u5e02\u573a\u4e0a\u5e76\u4e0d\u5e38\u89c1\uff0c\u6240\u4ee5\u6211\u4eec\u6765\u63a2\u7a76\u4e00\u4e0b\u4e3a\u4ec0\u4e48\u6ca1\u6709MQ<\/p>\n","protected":false},"author":1,"featured_media":3671,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-global-header-display":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","footnotes":""},"categories":[36],"tags":[87],"class_list":["post-32888","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog","tag-cgq"],"_links":{"self":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/32888","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/comments?post=32888"}],"version-history":[{"count":0,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/32888\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media\/3671"}],"wp:attachment":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media?parent=32888"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/categories?post=32888"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/tags?post=32888"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}