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
Gizzard Quick Intro (Korean)
Search
Hyunseok Hwang
August 02, 2012
Technology
2
130
Gizzard Quick Intro (Korean)
Quick introduction for Gizzard which is a data store middleware from Twitter (Korean ver.)
Hyunseok Hwang
August 02, 2012
Tweet
Share
Other Decks in Technology
See All in Technology
これでもう迷わない!Jetpack Composeの書き方実践ガイド
zozotech
PRO
0
140
AWS環境のリソース調査を Claude Code で効率化 / aws investigate with cc devio2025
masahirokawahara
2
1.4k
5年目から始める Vue3 サイト改善 #frontendo
tacck
PRO
3
200
20250903_1つのAWSアカウントに複数システムがある環境におけるアクセス制御をABACで実現.pdf
yhana
3
490
共有と分離 - Compose Multiplatform "本番導入" の設計指針
error96num
1
220
Platform開発が先行する Platform Engineeringの違和感
kintotechdev
3
510
2025年夏 コーディングエージェントを統べる者
nwiizo
0
120
フィンテック養成勉強会#56
finengine
0
130
自作JSエンジンに推しプロポーザルを実装したい!
sajikix
1
160
COVESA VSSによる車両データモデルの標準化とAWS IoT FleetWiseの活用
osawa
1
220
生成AI時代のデータ基盤設計〜ペースレイヤリングで実現する高速開発と持続性〜 / Levtech Meetup_Session_2
sansan_randd
1
140
おやつは300円まで!の最適化を模索してみた
techtekt
PRO
0
290
Featured
See All Featured
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
15
1.6k
BBQ
matthewcrist
89
9.8k
The Art of Programming - Codeland 2020
erikaheidi
55
13k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
111
20k
It's Worth the Effort
3n
187
28k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
50k
VelocityConf: Rendering Performance Case Studies
addyosmani
332
24k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
139
34k
Building a Scalable Design System with Sketch
lauravandoore
462
33k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
30
9.6k
Transcript
Gizzard Quick Intro 황현석
[email protected]
목차 •Gizzard? •DB Scaling 주요 방법 소개 •왜 Gizzard를 만들었나?
•Gizzard의 특징 •Gizzard 사용하기 •Gizzard use case
Gizzard A library for creating distributed Data Store (a.k.a Data
Store sharding middleware)
DB Scaling 주요 방법 •Replication •Partitioning •Sharding
Replication •동일한 데이터를 중복하여 저장 •목적 •데이터 안정성 (reliability) •가용성
(availability) •Fail over, Fault tolerance •LB: Read/Write Off-loading •Backup
Partitioning •DB 데이터를 쪼개어 저장 •유형 •Horizontal : row 단위
•Vertical : table 단위 •목적 •성능 (performance) •가용성 (availability)
Sharding •여러 개의 노드에 걸쳐 Horizontal Partitioning •일반적으로 Replication을 수반함
•Shared-Nothing + Aggregation Cost •Shard Key is Key! •목적 •성능 - 인덱스 크기와 밀접한 관련 •가용성
왜 Gizzard를 만들었나? by Twitter •애플리케이션에서 Sharding을 구현하는 것은 정말
어렵고 골치아픈 문제 •3rd Party Open Source Framework은 Web 특화적인 문제에 알맞지 않음
Gizzard의 특징
Middleware •웹 앱과 저장소 사이에서 네트워킹 서비스를 제공 •여러 개의
Gizzard를 띄워 TCP 커넥션 갯수 제한을 늘릴 수 있음 •Scala로 구현됨 (w/ JVM)
다양한 Back-end Data Store 지원 •네크워킹이 가능한 저장소라면 무엇이든 지원
•예. RDB(MySQL등), Lucene, Redis, ... •의도한 순서대로 저장하는 것을 보장 안함 •저장 순서가 중요한 앱에서는 사용 못함
Forwarding Table을 통한 Partitioning •Fowarding Table에 특정 Shard의 id 범위를
맵핑 : Range 기반 •사용자 정의 해싱 함수로 균형도 조정 : Fun(id) •Custom Consistent Hashing도 지원되지만 추천 안함
Replication Tree •Logical Shard •데이터의 논리적인 범위를 묶어주는 branch node
•write/read 확산 규칙을 포함 •다양한 전략 구사 가능 (Write-Only, Read-Only, Replicate 등) •Custom 전략도 가능
Fault-tolerant •No Single Point Of Failure •특정 Replica 가 죽어도
나머지 정상 Replica로 장애없이 서비스 •Replica가 살아나면 버퍼링된 데이터로 비동기 쓰기 시도 -> 일종의 저널링 시스템 사용 •특정 Shard의 모든 Replica가 죽어도 다른 Shard에는 영향 없음 •비동기 복구 전략 때문에 쓰기 트랜잭션은 순서와 무관 하게 수행 될 수 있어야 함
Migration •로드 분산을 위한 노드 추가 시 마이그레이션 지원 •마이그레이션이
완료될 때 까지 •쓰기 : WriteOnly, Datastore A •읽기 : Datastore A
쓰기 충돌 해결 •동일 레코드를 변경하려는 연산이 동시에 요청되었을 때
발생 •쓰기 연산이 순서에는 무관해야 •각 쓰기 연산이 독립적이고 멱등(idempotent) 하며 교환 가능하게 모델을 설계해야 함
Gizzard 사용하기 •서버 : Gizzard 기반의 분산 Key-Value Store 인
Rowz를 내려받아 커스터마이징 •클라이언트 : Thrift, Gizzmo, Custom Driver •https://github.com/twitter/gizzard/blob/ master/doc/using.md
Gizzard Use Case •T-bird •Distributed MySQL-backed DB by Twitter •https://github.com/twitter/haplocheirus
•Redis-backed storage engine for timelines by Twitter •https://github.com/twitter/flockdb •Distributed MySQL-backed Graph DB by Twitter
감사합니다. https://github.com/twitter/gizzard