This document discusses messaging queues and platforms. It begins with an introduction to messaging queues and their core components. It then provides a table comparing 8 popular open source messaging platforms: Apache Kafka, ActiveMQ, RabbitMQ, NATS, NSQ, Redis, ZeroMQ, and Nanomsg. The document discusses using Apache Kafka for streaming and integration with Google Pub/Sub, Dataflow, and BigQuery. It also covers benchmark testing of these platforms, comparing throughput and latency. Finally, it emphasizes that messaging queues can help applications by allowing producers and consumers to communicate asynchronously.
This document discusses messaging queues and platforms. It begins with an introduction to messaging queues and their core components. It then provides a table comparing 8 popular open source messaging platforms: Apache Kafka, ActiveMQ, RabbitMQ, NATS, NSQ, Redis, ZeroMQ, and Nanomsg. The document discusses using Apache Kafka for streaming and integration with Google Pub/Sub, Dataflow, and BigQuery. It also covers benchmark testing of these platforms, comparing throughput and latency. Finally, it emphasizes that messaging queues can help applications by allowing producers and consumers to communicate asynchronously.
52. 近年見直され始めたCAP定理
✘ Please stop calling databases CP or AP — Martin Kleppmann's blog
✗ CAPの定義はあまり現実に即していない
■ Linearizabilityは必要な場合が少ない
(Eventual Consistencyで十分な場合が多い)
■ 可用性の定義が甘い
(レスポンスを返すだけでは甘い)
■ Partition-Toleranceは実際は取らざるを得ない
✗ CAP定理が対象にしているシステムは狭い
■ 対象は単一のデータオブジェクト
■ 考慮されている故障がネットワーク分断のみ
■ 現実的に問題となるLatency(Performance)には言及がない
53. 近年見直され始めたCAP定理 cont.
✘ Please stop calling databases CP or AP — Martin Kleppmann's blog
✗ データベース全体でCP/APとカテゴライズするのは誤り
■ 一つのソフトウェアの中にも様々な一貫性がある
■ CAP定理の元では C も A もないPのみのシステムもあるのに
多く使われているものも在る(例: Zookeeper)
● Zookeeperは使い方によってCPにもAPにもなる
■ Eric BrewerですらCAPという分類は単純すぎた
と認めている
54. 近年見直され始めたCAP定理 cont.
✘ Please stop calling databases CP or AP — Martin Kleppmann's blog
✗ これまで多くのデータベース設計に示唆を与えてきた
CAP定理の分類が使えないのならどうすれば?
✗ 自分で考えられるようになりましょう。
多くの先人達も同じ課題について考えています。
■ Doug Terryの論文が最初のおすすめ
● Replicated Data Consistency Explained Through Baseball
(野球の例を使って整合性の様々な異なるレベルを説明)
■ Highly Available Transactions: Virtues and Limitations (full)
● 整合性レベルの階層とトランザクション分離、可用性に
ついての考察
■ Designing Data Intensive Applications を読む
■ etc.
59. 付録: 参考文献 (FLP編)
✘ 分散システムについて語るときに我々の語ること― 分散システム... - POSTD
✗ 分散システムにまつわる概念をいろいろ解説。
✗ 入門的に読むととても良い。
✘ Impossibility of Distributed Consensus with One Faulty Process
✗ 原典。FLPの言わんとする所について何かに詰まったら必ず戻る場所。
✘ A Brief Tour of FLP Impossibility
✗ FLP証明の解説
✗ Zookeeperのcommitterでcloudera所属の@HenryR さんのブログThe Paper Trail より
✗ とてもわかり易いブログ満載。興味の在る方は他の記事も必読。
✘ Introduction to Reliable and Secure Distributed Programming
✗ 良書。分散システムを理論からしっかり学びたい人におすすめ。
✘ Stumbling over consensus research: Misunderstandings and issues
✗ concensusにまつわる誤解をFLPが前提としているシステムモデルを確認しながら解説
してくれる論文
✘ 分散システムについて語らせてくれ, 本当は恐ろしい分散システムの話
✗ NTTの熊崎さんによる分散システムについての解説
60. 付録: 参考文献 (CAP定理編)
✘ Brewer’s Conjecture and the Feasibility of Consistent, Available, Partition-Tolerant Web Services
✗ 原典。証明されていることはすべてここに。
✗ 日本語訳あり
✘ Perspectives on the CAP Theorem - Research
✗ 証明者(Gilbert, Lynch)によって12年後に書かれた CAP Theormの現代における解釈と現実的に取られている
解法について
✘ CAP Twelve Years Later: How the ''Rules'' Have Changed
✗ Eric Brewer自身が12年を振り返り、CAP定理への反省と現代における再解釈について考察した記事
✗ 日本語訳あり
✘ Please stop calling databases CP or AP — Martin Kleppmann's blog
✗ データベースをCP/APと分類するのは雑すぎる、現実的でないと唱えた記事
✗ Designing Data-Intensive Applicationの著者のMartin Kleppmanさんの記事
✗ 日本語訳あり
✘ Designing Data-Intensive Application
✗ とっても良書。分散システムの基礎概念がとてもよくまとまっている
✗ CAPへの批判も入っている
✘ Replicated Data Consistency Explained Through Baseball
✗ 整合性の様々な分類について述べられた論文
✗ Azure Cosmos DBが提供する整合性の元になっていると思われる