具体描述
作者简介
目录信息
Preface
How to Read This Book
Acknowledgments
I. Setting the Stage
1. Introduction
2. The Origins of Streaming
3. Is Kafka What You Think It Is?
Kafka Is Like REST but Asynchronous?
Kafka Is Like a Service Bus?
Kafka Is Like a Database?
What Is Kafka Really? A Streaming Platform
4. Beyond Messaging: An Overview of the Kafka Broker
The Log: An Efficient Structure for Retaining and Distributing Messages
Linear Scalability
Segregating Load in Multiservice Ecosystems
Maintaining Strong Ordering Guarantees
Ensuring Messages Are Durable
Load-Balance Services and Make Them Highly Available
Compacted Topics
Long-Term Data Storage
Security
Summary
II. Designing Event-Driven Systems
5. Events: A Basis for Collaboration
Commands, Events, and Queries
Coupling and Message Brokers
Is Loose Coupling Always Good?
Essential Data Coupling Is Unavoidable
Using Events for Notification
Using Events to Provide State Transfer
Which Approach to Use
The Event Collaboration Pattern
Relationship with Stream Processing
Mixing Request- and Event-Driven Protocols
Summary
6. Processing Events with Stateful Functions
Making Services Stateful
The Event-Driven Approach
The Pure (Stateless) Streaming Approach
The Stateful Streaming Approach
The Practicalities of Being Stateful
Summary
7. Event Sourcing, CQRS, and Other Stateful Patterns
Event Sourcing, Command Sourcing, and CQRS in a Nutshell
Version Control for Your Data
Making Events the Source of Truth
Command Query Responsibility Segregation
Materialized Views
Polyglot Views
Whole Fact or Delta?
Implementing Event Sourcing and CQRS with Kafka
Build In-Process Views with Tables and State Stores in Kafka Streams
Writing Through a Database into a Kafka Topic with Kafka Connect
Writing Through a State Store to a Kafka Topic in Kafka Streams
Unlocking Legacy Systems with CDC
Query a Read-Optimized View Created in a Database
Memory Images/Prepopulated Caches
The Event-Sourced View
Summary
III. Rethinking Architecture at Company Scales
8. Sharing Data and Services Across an Organization
Encapsulation Isn’t Always Your Friend
The Data Dichotomy
What Happens to Systems as They Evolve?
The God Service Problem
The REST-to-ETL Problem
Make Data on the Outside a First-Class Citizen
Don’t Be Afraid to Evolve
Summary
9. Event Streams as a Shared Source of Truth
A Database Inside Out
Summary
10. Lean Data
If Messaging Remembers, Databases Don’t Have To
Take Only the Data You Need, Nothing More
Rebuilding Event-Sourced Views
Kafka Streams
Databases and Caches
Handling the Impracticalities of Data Movement
Automation and Schema Migration
The Data Divergence Problem
Summary
IV. Consistency, Concurrency, and Evolution
11. Consistency and Concurrency in Event-Driven Systems
Eventual Consistency
Timeliness
Collisions and Merging
The Single Writer Principle
Command Topic
Single Writer Per Transition
Atomicity with Transactions
Identity and Concurrency Control
Limitations
Summary
12. Transactions, but Not as We Know Them
The Duplicates Problem
Using the Transactions API to Remove Duplicates
Exactly Once Is Both Idempotence and Atomic Commit
How Kafka’s Transactions Work Under the Covers
Store State and Send Events Atomically
Do We Need Transactions? Can We Do All This with Idempotence?
What Can’t Transactions Do?
Making Use of Transactions in Your Services
Summary
13. Evolving Schemas and Data over Time
Using Schemas to Manage the Evolution of Data in Time
Handling Schema Change and Breaking Backward Compatibility
Collaborating over Schema Change
Handling Unreadable Messages
Deleting Data
Triggering Downstream Deletes
Segregating Public and Private Topics
Summary
V. Implementing Streaming Services with Kafka
14. Kafka Streams and KSQL
A Simple Email Service Built with Kafka Streams and KSQL
Windows, Joins, Tables, and State Stores
Summary
15. Building Streaming Services
An Order Validation Ecosystem
Join-Filter-Process
Event-Sourced Views in Kafka Streams
Collapsing CQRS with a Blocking Read
Scaling Concurrent Operations in Streaming Systems
Rekey to Join
Repartitioning and Staged Execution
Waiting for N Events
Reflecting on the Design
A More Holistic Streaming Ecosystem
Summary
· · · · · · (收起)
读后感
用户评价
这本书的价值在于,它成功地将看似分散的系统组件知识点,整合进了一个统一的、以“流”和“状态变化”为核心的宏大叙事框架中。它不是一本单纯的技术手册,更像是一本关于如何“管理复杂性”的哲学指南。作者对于系统边界、责任划分的强调,体现了一种高屋建瓴的架构师思维。我发现自己在阅读过程中,不断地调整自己对“微服务”乃至“函数计算”的理解深度,不再仅仅关注实现细节,而是开始思考它们在整个数据流中的角色定位。书中对错误处理和可观测性的论述尤为精辟,作者没有将它们视为事后补救的措施,而是融入到系统设计之初的核心考量。这种先验性的设计哲学,是真正区分优秀架构与平庸架构的关键所在,对于希望从“代码实现者”跃升为“系统设计者”的专业人士而言,这本书提供的思维跳跃是里程碑式的。
读完这本书,我最大的感受是它提供了一种全新的、更具前瞻性的思考视角,彻底颠覆了我过去对传统请求/响应模式的一些固有限制性认知。作者没有止步于描述现有的技术栈,而是深入探讨了驱动系统行为的底层逻辑和设计哲学。书中对模块间解耦的探讨,尤其细致入微,每一个设计决策的背后都充满了对长期维护性和灵活性的深思熟虑。比如,关于如何设计一个能够优雅应对突发流量洪峰的机制,书中的方案不仅考虑了性能指标,更关注了系统的弹性边界和故障隔离。阅读过程中,我时不时会停下来,在脑海中重构自己正在负责的项目,试图套用书中的理念进行优化,这种启发性是无价的。对于那些厌倦了简单 CRUD 开发,渴望深入理解大型分布式系统内部运作机制的开发者,这本书绝对能让你大开眼界,它提供的不仅仅是工具箱,更是一套精密的蓝图绘制方法论。
我不得不说,这本书在讲解系统设计中的权衡(Trade-offs)方面做得非常出色,这是许多同类书籍往往避重就轻的地方。作者坦诚地剖析了每一种设计选择背后的成本、收益和潜在的陷阱。例如,在讨论数据存储方案时,书中没有偏向任何一家商业产品,而是聚焦于背后的存储原理和一致性保证的取舍,这使得读者能够基于原理而非品牌来做出决策。书中的语言风格非常直接、专业,没有多余的废话,每一个句子都似乎承载着重要的信息量。我特别欣赏它对于构建高内聚、低耦合系统的具体指导,这些指导并非空洞的口号,而是落到实处的编码规范和接口设计原则。对于希望在面对海量用户和数据挑战时,依然能够保持系统清晰、可控的技术领导者和资深工程师来说,这本书提供的不仅是知识,更是一种面对技术挑战时的沉着与自信。
这本书的行文风格极其严谨,学术性与工程实用性达到了一个微妙的平衡点。我尤其欣赏作者在引用前沿研究成果时,能够清晰地区分理论的成熟度和实际落地的难度。书中大量的图表和流程分解,对于理解异步通信的复杂性帮助极大,那些原本在我看来有些晦涩难懂的概念,通过图示化处理后,变得清晰可见,脉络分明。我发现作者在选择案例时非常用心,既有互联网巨头的影子,也有面向特定业务场景的定制化解决方案,这使得书中的知识更具普适性和可迁移性。对于那些致力于构建下一代复杂信息系统的技术人员来说,这本书提供了一个坚实的基础,它教会我们如何从“解决眼前问题”过渡到“构建面向未来的系统”。阅读过程中需要投入相当的注意力,但每一次深入思考都会带来巨大的回报,绝对是一本需要反复研读的经典。
这本书的封面设计得相当引人注目,那种现代感和技术感融合得恰到好处,让人一眼就能感受到它所蕴含的深度。从目录上看,内容涵盖了系统架构的多个重要方面,尤其是那些关于如何构建高可用、高可扩展系统的讨论,着实抓住了当前业界最关注的痛点。我尤其欣赏作者在讲解复杂概念时所采用的类比和实例,这使得即便是初次接触这些高级主题的读者也能迅速建立起清晰的认知框架。书中对设计原则的阐述非常扎实,不是那种空泛的理论堆砌,而是紧密结合实际工程实践,告诉你“为什么这么做”以及“这么做的好处在哪里”。特别是关于数据一致性模型的那几个章节,简直是教科书级别的讲解,清晰地梳理了不同模型之间的权衡取舍,让人茅塞顿懂。整体阅读体验非常流畅,文字功底深厚,逻辑层次分明,仿佛有一位经验丰富的架构师在你身边手把手进行指导。这本书无疑是系统设计领域的一部重量级著作,对于希望提升自己架构思维和实战能力的工程师来说,绝对是案头必备的参考书。
好久不看技术书了,感觉不错,以后吹牛底气又足了一点点😂
被迫四天读完了这本书,完全是填鸭式学习。书中较靠前的经验之谈确实在先前项目的实际运用中遇到了,后面还有需要咀嚼的内容也不少。应该会给系统设计带来不少帮助。
被迫四天读完了这本书,完全是填鸭式学习。书中较靠前的经验之谈确实在先前项目的实际运用中遇到了,后面还有需要咀嚼的内容也不少。应该会给系统设计带来不少帮助。
被迫四天读完了这本书,完全是填鸭式学习。书中较靠前的经验之谈确实在先前项目的实际运用中遇到了,后面还有需要咀嚼的内容也不少。应该会给系统设计带来不少帮助。
被迫四天读完了这本书,完全是填鸭式学习。书中较靠前的经验之谈确实在先前项目的实际运用中遇到了,后面还有需要咀嚼的内容也不少。应该会给系统设计带来不少帮助。