注冊 | 登錄讀書好,好讀書,讀好書!
讀書網(wǎng)-DuShu.com
當(dāng)前位置: 首頁出版圖書科學(xué)技術(shù)計算機/網(wǎng)絡(luò)軟件與程序設(shè)計RocketMQ消息中間件實戰(zhàn)派(上下冊)

RocketMQ消息中間件實戰(zhàn)派(上下冊)

RocketMQ消息中間件實戰(zhàn)派(上下冊)

定 價:¥236.00

作 者: 胡弦
出版社: 電子工業(yè)出版社
叢編項:
標 簽: 暫缺

ISBN: 9787121469701 出版時間: 2024-01-01 包裝: 平塑勒
開本: 頁數(shù): 字數(shù):  

內(nèi)容簡介

  本書覆蓋了開發(fā)人員在落地分布式架構(gòu)過程中使用RocketMQ 的主要技術(shù)點,包括RocketMQ 的 高性能通信渠道、生產(chǎn)消息、消費消息、存儲消息、分布式事務(wù)消息、消息的可追蹤性、消息的穩(wěn)定性、消息的高并發(fā)、消息的高可用、消息的高性能和RocketMQ 5.x 的新特性。采用"是什么→怎么用→什么原理(源碼分析)”的主線來講解這些技術(shù)點。 本書的主要目標:①讓讀者在動手中學(xué)習(xí),而不是"看書時好像全明白了,一動手卻發(fā)現(xiàn)什么都不會”;②讓讀者掌握整個RocketMQ 生態(tài)的全棧技術(shù)和最佳實踐,而不是只有RocketMQ 框架;③讓讀者從RocketMQ 體系化的視角熟悉RocketMQ 的核心原理,而不是零散且碎片化;④讓讀者成為消息中間件領(lǐng)域的技術(shù)專家或架構(gòu)師,而不只是熟悉RocketMQ;⑤讓讀者具備自研消息中間件的能力,而不是僅停留在源碼分析的層次,"授人以魚,不如授人以漁”是本書最大的宗旨。 本書適合對分布式架構(gòu)及支撐分布式架構(gòu)落地的中間件感興趣的技術(shù)開發(fā)人員。無論讀者是否接觸過 分布式消息中間件,只要具備一定的Java 開發(fā)基礎(chǔ),都能通過本書的學(xué)習(xí)快速掌握分布式架構(gòu)中消息中間件的開發(fā)技能,并利用RocketMQ 消息中間件支撐分布式架構(gòu)的落地。

作者簡介

  曾就職于網(wǎng)易考拉、微醫(yī)集團、連連支付、政采云等杭州一線獨角獸公司,高級技術(shù)專家(P8)和業(yè)務(wù)負責(zé)人,具備跨境電商、跨境支付等業(yè)務(wù)領(lǐng)域0-1的架構(gòu)設(shè)計和開發(fā)落地能力,擅長高并發(fā)、高可用、和高性能系統(tǒng)架構(gòu)設(shè)計。

圖書目錄

第1 篇 基礎(chǔ)
第1 章 初識RocketMQ ·························.2
1.1 認識分布式架構(gòu) ····························.2
1.1.1 什么是分布式 ·······················.2
1.1.2 什么是架構(gòu) ··························.3
1.1.3 分布式架構(gòu)的冰與火 ··············.5
1.2 認識RocketMQ ·····························.7
1.2.1 什么是RocketMQ ··················.7
1.2.2 RocketMQ 與分布式架構(gòu) ·······.12
1.3 搭建RocketMQ 環(huán)境 ····················.13
1.3.1 了解RocketMQ 相關(guān)的安裝包 .13
1.3.2 搭建單Master 的單機環(huán)境 ·····.15
1.3.3 搭建多Master 的集群環(huán)境 ·····.15
1.3.4 搭建單Master 和單Slave 的集群環(huán)境 ·································.16
1.3.5 【實例】搭建Raft 集群環(huán)境 ··.18
1.4 RocketMQ 5.0 的新特性 ················.20
第2 章 實現(xiàn)通信渠道 ··························.22
2.1 認識通信渠道 ·····························.22
2.2 通信渠道的架構(gòu) ··························.25
2.2.1 認識Netty ·························.25
2.2.2 RocketMQ 通信渠道的架構(gòu) ····.29
2.3 使用Netty 實現(xiàn)通信渠道的原理 ······.33
2.3.1 實現(xiàn)通信渠道的通信協(xié)議 ······.33
2.3.2 實現(xiàn)客戶端通信渠道 ············.38
2.3.3 實現(xiàn)服務(wù)端通信渠道 ············.41
2.4 使用客戶端連接服務(wù)端 ·················.47
2.4.1 分析模塊通信渠道的類型 ······.48
2.4.2 連接服務(wù)端 ························.50
2.5 【實例】修改通信渠道客戶端和服務(wù)端的線程模型 ·······················.54
第3 章 消息路由信息的無狀態(tài)存儲和管理 ······································.61
3.1 了解消息路由信息 ·······················.61
3.2 Name Server 的架構(gòu) ·····················.68
3.2.1 認識無狀態(tài)架構(gòu) ··················.68
3.2.2 認識Name Server 架構(gòu) ·········.69
3.2.3 認識地址服務(wù)架構(gòu) ···············.72
3.2.4 【實例】用地址服務(wù)動態(tài)更新客戶端中的Name Server 節(jié)點的地址信息 ··························.74
3.3 “使用Name Server 存儲和管理消息路由信息”的原理 ·······················.77
3.3.1 Name Server 的啟動流程 ·······.77
3.3.2 注冊Broker Server ···············.84
3.3.3 取消注冊的業(yè)務(wù)場景和取消注冊Broker Server ···············.89
3.3.4 存儲和管理消息路由信息 ······.93
3.4 【實例】啟動多個Name Server 節(jié)點,模擬故障以驗證Name Server 節(jié)點的無狀態(tài)性 ·································.101
第4 章 生產(chǎn)消息和消費消息 ···············.104
4.1 生產(chǎn)和消費消息的模式 ················.104
4.1.1 生產(chǎn)消息 ··························.104
4.1.2 消費消息 ··························.110
4.2 消費消息的類型 ·························.116
4.2.1 集群消息 ··························.116
4.2.2 廣播消息 ··························.118
4.2.3 順序消息 ··························.119
4.2.4 并發(fā)消息 ··························.125
4.2.5 延遲消息 ··························.126
4.2.6 事務(wù)消息 ··························.130
4.3 生產(chǎn)消息 ··································.134
4.3.1 生產(chǎn)者SDK 的3 種使用方式 ································.135
4.3.2 采用“同步”模式生產(chǎn)消息 ···.137
4.3.3 采用“異步”模式生產(chǎn)消息 ···.142
4.3.4 采用“最多發(fā)送一次”模式生產(chǎn)消息 ··························.148
4.4 消費消息 ··································.152
4.4.1 采用pull 模式消費消息 ········.153
4.4.2 采用push 模式消費消息 ·······.171
4.4.3 采用pop 模式消費消息 ········.183
4.5 采用“請求/應(yīng)答”消息實現(xiàn)同步調(diào)用 ········································.197
4.5.1 “請求/應(yīng)答”消息的架構(gòu) ····.197
4.5.2 分析“請求/應(yīng)答”消息的過程 ································.198
4.6 【實例】生產(chǎn)者發(fā)送消息,消費者順序地消費消息 ·························.212
4.6.1 驗證“普通順序消息” ········.212
4.6.2 驗證“嚴格順序消息” ········.217
第5 章 存儲消息 ······························.219
5.1 認識存儲引擎 ····························.219
5.1.1 什么是存儲引擎 ·················.219
5.1.2 存儲引擎的架構(gòu) ·················.221
5.2 認識存儲模型 ····························.222
5.2.1 消息模型 ··························.222
5.2.2 文件模型 ··························.229
5.2.3 【實例】利用源碼遠程調(diào)試存儲模型 ································.236
5.3 啟動存儲引擎 ····························.238
5.3.1 初始化Broker Server 和存儲引擎 ································.238
5.3.2 啟動Broker Server 和存儲引擎 ································.247
5.3.3 【實例】動態(tài)修改存儲引擎的配置參數(shù) ··························.251
5.4 使用存儲引擎處理“儲存消息”的請求 ········································.253
5.4.1 接收并處理生產(chǎn)消息的請求 ································.254
5.4.2 存儲消息 ··························.257
5.4.3 【實例】利用存儲引擎實現(xiàn)批量地存儲消息 ·······················.262
5.5 對比存儲單條消息和批量消息的性能 ········································.263

第6 章 治理消息 ······························.268
6.1 如何治理消息 ····························.268
6.1.1 治理消息的目標 ·················.268
6.1.2 使用消息度量提供治理消息的依據(jù) ································.276
6.1.3 使用消息管控實現(xiàn)治理消息的落地 ································.280
6.2 認識命令控制臺和UI 控制臺 ········.285
6.2.1 什么是命令控制臺和UI控制臺 ·····························.285
6.2.2 啟動命令控制臺和UI控制臺 ·····························.289
6.2.3 使用對象池管理RocketMQDashboard 中通信渠道客戶端的核心類 ·····························.292
6.3 使用命令控制臺治理消息 ·············.298
6.3.1 執(zhí)行治理消息的命令 ···········.299
6.3.2 【實例】使用命令控制臺,完成
RocketMQ 集群的擴容 ·········.322
6.3.3 【實例】使用命令控制臺,完成
RocketMQ 集群的縮容 ·········.325
6.3.4 【實例】使用命令控制臺,動態(tài)增加Topic 的讀/寫消息隊列的數(shù)量 ·················.332
6.4 使用UI 控制臺治理消息 ··············.334
6.4.1 使用UI 控制臺治理消息的原理 ································.335
6.4.2 【實例】使用UI 控制臺手動地禁用消費者組 ····················.341
6.4.3 【實例

本目錄推薦

掃描二維碼
Copyright ? 讀書網(wǎng) ranfinancial.com 2005-2020, All Rights Reserved.
鄂ICP備15019699號 鄂公網(wǎng)安備 42010302001612號