Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Failure test with Pumba
Search
Yoshinori SHIMADA
September 03, 2018
Technology
0
880
Failure test with Pumba
Yoshinori SHIMADA
September 03, 2018
Tweet
Share
Other Decks in Technology
See All in Technology
Digitization部 紹介資料
sansan33
PRO
1
6.8k
超初心者からでも大丈夫!オープンソース半導体の楽しみ方〜今こそ!オレオレチップをつくろう〜
keropiyo
0
110
Tebiki Engineering Team Deck
tebiki
0
24k
量子クラウドサービスの裏側 〜Deep Dive into OQTOPUS〜
oqtopus
0
110
小さく始めるBCP ― 多プロダクト環境で始める最初の一歩
kekke_n
1
410
レガシー共有バッチ基盤への挑戦 - SREドリブンなリアーキテクチャリングの取り組み
tatsukoni
0
220
コスト削減から「セキュリティと利便性」を担うプラットフォームへ
sansantech
PRO
3
1.5k
15 years with Rails and DDD (AI Edition)
andrzejkrzywda
0
190
Red Hat OpenStack Services on OpenShift
tamemiya
0
110
マーケットプレイス版Oracle WebCenter Content For OCI
oracle4engineer
PRO
5
1.6k
広告の効果検証を題材にした因果推論の精度検証について
zozotech
PRO
0
180
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
10k
Featured
See All Featured
Crafting Experiences
bethany
1
49
Information Architects: The Missing Link in Design Systems
soysaucechin
0
770
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Technical Leadership for Architectural Decision Making
baasie
1
240
Building Flexible Design Systems
yeseniaperezcruz
330
40k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
140
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.4k
How to Think Like a Performance Engineer
csswizardry
28
2.4k
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
220
Code Review Best Practice
trishagee
74
20k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
57
50k
Transcript
Pumbaを使った異常系試験 @simd_nyan
$ whoami • Yoshinori Shimada @simd_nyan • 仕事 – Software
Engineer@通信会社 – クラウドサービスの開発 • 好きなプログラミング言語 – 言語 • 好きなテストフレームワーク – Gherkin/Cucumber • Dockerの好きなところ – 「俺の環境では動いた」の殲滅 ポータビリティ – 日がな1日イメージサイズ最小を目指す愉しみ 軽量
他部署 自分たちが 作っているシステム マイクロサービスなシステムの構成 DB App 謎システム App2 App1 App3
謎システム 謎システム 謎システム 謎システム
結合テスト環境のコンテナ化 DB のコンテナ App のコンテナ テスト コード App2 のモック App1
のモック App3 のコンテナ docker-compose
docker-compose 結合テストでの異常系試験の想定 DB のコンテナ App のコンテナ テスト コード App2 のモック
App1 のモック App3 のコンテナ 遅延が… 死んでる…
Pumba • Pumba: Chaos testing tool for Docker – https://github.com/alexei-led/pumba
• できること COMMANDS: kill kill specified containers netem emulate the properties of wide area networks pause pause all processes stop stop containers rm remove containers help, h Shows a list of commands or help for one command
ネットワーク遅延を発生させる DB のコンテナ App のコンテナ テスト コード App2 のモック App1
のモック App3 のコンテナ docker-compose pumba pumba netem --duration 999m delay --time 30 app3
ネットワーク遅延を発生させる DB のコンテナ App のコンテナ テスト コード App2 のモック App1
のモック App3 のコンテナ docker-compose pumba pumba netem --duration 999m delay --time 30 app3
Appを落とす DB のコンテナ App のコンテナ テスト コード App2 のモック App1
のモック App3 のコンテナ docker-compose pumba pumba pause --duration 999m 30 app1
Appを落とす DB のコンテナ App のコンテナ テスト コード App2 のモック App1
のモック App3 のコンテナ docker-compose pumba pumba pause --duration 999m 30 app1
Network Emulation(netem)コマンドについて • delay – 遅延 • loss – パケロス
• loss-state – 4-state Markov モデルのパケロス • loss-gemodel – Gilbert-Elliot loss モデルのパケロス • rate – レートリミット • 内部的にはtcを利用 – iproute2とかを入れておく必要有