SlideShare une entreprise Scribd logo
1  sur  16
Télécharger pour lire hors ligne
gizzard, DAL and more
        @tangfl

        2011.2.22
gizzard 1

• sharding framework
• extract from FlockDB
• written in Java/Scala
gizzard 2

• middle ware :
 • like mysql-proxy ?
• any backends
 • like mytrigger ?
 • adapter ?
gizzard 3
• rules: forwarding table
 • maps key ranges to partitions
• replication tree
gizzard 4

• eventually consistent
 • idempotent : f(f(n)) = f(n)
 • commutative : f(a) + f(b) = f(b) + f(a)
 • retry queue
gizzard 5

• gracefully failures
 • read : route to remain ones
 • write : make high priority to remain
    replicas if any in a shard are unavailable
 • retry queue
gizzard 6

• gracefully migrations
 • replica tree
 • WriteOnly shard
gizzard 7

• summary
 • nothing new
 • Get work done
DAL 1

• Data Access Layer
• from iMobile
• by longker, simaliu and fulin
• Not only sharding
DAL 2

• data table, hash by pri id, less index
• index tables, hash by any “where field” on
  demand
• front php devs : I don’t care !
DAL 3


• insert / update / delete : auto update index
  table
• query : analyze sql, choose best index table
DAL 4


• build-in cache : php don’t care about cache
  anymore
DAL 5

• any backend
 • treat Lucene just like mysql : select field
    from table where condition
• no replica
 • backend do the job
DAL 6

• summary
 • nothing new
 • Get work done
more
• Discuss
 • fans_all list in redis
 • vary from 0 to 500w
 • single hash at most 5000
 • auto resharding
 • async
Thanks


• @tangfl http://t.sina.com.cn
• http://blog.fulin.org

Contenu connexe

Tendances

Iasi code camp 12 october 2013 jax-rs-jee-ecosystem - catalin mihalache
Iasi code camp 12 october 2013   jax-rs-jee-ecosystem - catalin mihalacheIasi code camp 12 october 2013   jax-rs-jee-ecosystem - catalin mihalache
Iasi code camp 12 october 2013 jax-rs-jee-ecosystem - catalin mihalache
Codecamp Romania
 
Spider进化论
Spider进化论Spider进化论
Spider进化论
cjhacker
 

Tendances (19)

Apache ManifoldCF
Apache ManifoldCFApache ManifoldCF
Apache ManifoldCF
 
SearchHub - How to Spend Your Summer Keeping it Real: Presented by Grant Inge...
SearchHub - How to Spend Your Summer Keeping it Real: Presented by Grant Inge...SearchHub - How to Spend Your Summer Keeping it Real: Presented by Grant Inge...
SearchHub - How to Spend Your Summer Keeping it Real: Presented by Grant Inge...
 
Why Is My Solr Slow?: Presented by Mike Drob, Cloudera
Why Is My Solr Slow?: Presented by Mike Drob, ClouderaWhy Is My Solr Slow?: Presented by Mike Drob, Cloudera
Why Is My Solr Slow?: Presented by Mike Drob, Cloudera
 
Iasi code camp 12 october 2013 jax-rs-jee-ecosystem - catalin mihalache
Iasi code camp 12 october 2013   jax-rs-jee-ecosystem - catalin mihalacheIasi code camp 12 october 2013   jax-rs-jee-ecosystem - catalin mihalache
Iasi code camp 12 october 2013 jax-rs-jee-ecosystem - catalin mihalache
 
Parallel SQL and Streaming Expressions in Apache Solr 6
Parallel SQL and Streaming Expressions in Apache Solr 6Parallel SQL and Streaming Expressions in Apache Solr 6
Parallel SQL and Streaming Expressions in Apache Solr 6
 
Solrcloud Leader Election
Solrcloud Leader ElectionSolrcloud Leader Election
Solrcloud Leader Election
 
Spider进化论
Spider进化论Spider进化论
Spider进化论
 
Utilizing the OpenNTF Domino API
Utilizing the OpenNTF Domino APIUtilizing the OpenNTF Domino API
Utilizing the OpenNTF Domino API
 
Efficient Scalable Search in a Multi-Tenant Environment: Presented by Harry H...
Efficient Scalable Search in a Multi-Tenant Environment: Presented by Harry H...Efficient Scalable Search in a Multi-Tenant Environment: Presented by Harry H...
Efficient Scalable Search in a Multi-Tenant Environment: Presented by Harry H...
 
Java SE 7 New Features and Enhancements
Java SE 7 New Features and EnhancementsJava SE 7 New Features and Enhancements
Java SE 7 New Features and Enhancements
 
Introducing Infinispan
Introducing InfinispanIntroducing Infinispan
Introducing Infinispan
 
Apache ManifoldCF @ Linux Day 2012
Apache ManifoldCF @ Linux Day 2012Apache ManifoldCF @ Linux Day 2012
Apache ManifoldCF @ Linux Day 2012
 
Azure Redis Cache - Cache on Steroids!
Azure Redis Cache - Cache on Steroids!Azure Redis Cache - Cache on Steroids!
Azure Redis Cache - Cache on Steroids!
 
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
 
Building and Running Solr-as-a-Service: Presented by Shai Erera, IBM
Building and Running Solr-as-a-Service: Presented by Shai Erera, IBMBuilding and Running Solr-as-a-Service: Presented by Shai Erera, IBM
Building and Running Solr-as-a-Service: Presented by Shai Erera, IBM
 
Scala at Treasure Data
Scala at Treasure DataScala at Treasure Data
Scala at Treasure Data
 
Solr4 nosql search_server_2013
Solr4 nosql search_server_2013Solr4 nosql search_server_2013
Solr4 nosql search_server_2013
 
Ce e nou in Rails 4
Ce e nou in Rails 4Ce e nou in Rails 4
Ce e nou in Rails 4
 
Embedded systems training India - Linux system programming and kernel intern...
Embedded systems training India  - Linux system programming and kernel intern...Embedded systems training India  - Linux system programming and kernel intern...
Embedded systems training India - Linux system programming and kernel intern...
 

En vedette (10)

Redis大数据之路 dtcc-唐福林
Redis大数据之路 dtcc-唐福林Redis大数据之路 dtcc-唐福林
Redis大数据之路 dtcc-唐福林
 
股市动荡下的雪球架构进化历程
股市动荡下的雪球架构进化历程股市动荡下的雪球架构进化历程
股市动荡下的雪球架构进化历程
 
雪球大数据体系实践
雪球大数据体系实践雪球大数据体系实践
雪球大数据体系实践
 
物联网与微博平台探索
物联网与微博平台探索物联网与微博平台探索
物联网与微博平台探索
 
我的奋斗 @ weibo
我的奋斗 @ weibo我的奋斗 @ weibo
我的奋斗 @ weibo
 
移动时代端到端的稳定性保障经验谈
移动时代端到端的稳定性保障经验谈移动时代端到端的稳定性保障经验谈
移动时代端到端的稳定性保障经验谈
 
新浪微博平台稳定性与代码质量
新浪微博平台稳定性与代码质量新浪微博平台稳定性与代码质量
新浪微博平台稳定性与代码质量
 
订阅互联网
订阅互联网订阅互联网
订阅互联网
 
雪球服务化实践历程.Print
雪球服务化实践历程.Print雪球服务化实践历程.Print
雪球服务化实践历程.Print
 
Culture
CultureCulture
Culture
 

Similaire à Gizzard, DAL and more

Scaling etl with hadoop shapira 3
Scaling etl with hadoop   shapira 3Scaling etl with hadoop   shapira 3
Scaling etl with hadoop shapira 3
Gwen (Chen) Shapira
 
Scaling MySQL Using Fabric
Scaling MySQL Using FabricScaling MySQL Using Fabric
Scaling MySQL Using Fabric
Remote MySQL DBA
 
Merge2013 mwarren-presentation1.pptx(pv6)
Merge2013 mwarren-presentation1.pptx(pv6)Merge2013 mwarren-presentation1.pptx(pv6)
Merge2013 mwarren-presentation1.pptx(pv6)
Mark Warren
 
What every developer should know about database scalability, PyCon 2010
What every developer should know about database scalability, PyCon 2010What every developer should know about database scalability, PyCon 2010
What every developer should know about database scalability, PyCon 2010
jbellis
 
Cassandra vs. Redis
Cassandra vs. RedisCassandra vs. Redis
Cassandra vs. Redis
Tim Lossen
 
Solr Black Belt Pre-conference
Solr Black Belt Pre-conferenceSolr Black Belt Pre-conference
Solr Black Belt Pre-conference
Erik Hatcher
 
Scalding by Adform Research, Alex Gryzlov
Scalding by Adform Research, Alex GryzlovScalding by Adform Research, Alex Gryzlov
Scalding by Adform Research, Alex Gryzlov
Vasil Remeniuk
 

Similaire à Gizzard, DAL and more (20)

KeyValue Stores
KeyValue StoresKeyValue Stores
KeyValue Stores
 
MariaDB: The 2012 Edition
MariaDB: The 2012 EditionMariaDB: The 2012 Edition
MariaDB: The 2012 Edition
 
Scaling etl with hadoop shapira 3
Scaling etl with hadoop   shapira 3Scaling etl with hadoop   shapira 3
Scaling etl with hadoop shapira 3
 
视觉中国的MongoDB应用实践(QConBeijing2011)
视觉中国的MongoDB应用实践(QConBeijing2011)视觉中国的MongoDB应用实践(QConBeijing2011)
视觉中国的MongoDB应用实践(QConBeijing2011)
 
MongoDB开发应用实践
MongoDB开发应用实践MongoDB开发应用实践
MongoDB开发应用实践
 
Scaling MySQL Using Fabric
Scaling MySQL Using FabricScaling MySQL Using Fabric
Scaling MySQL Using Fabric
 
Scaling MySQL using Fabric
Scaling MySQL using FabricScaling MySQL using Fabric
Scaling MySQL using Fabric
 
MariaDB - a MySQL Replacement #SELF2014
MariaDB - a MySQL Replacement #SELF2014MariaDB - a MySQL Replacement #SELF2014
MariaDB - a MySQL Replacement #SELF2014
 
Why MariaDB?
Why MariaDB?Why MariaDB?
Why MariaDB?
 
Merge2013 mwarren-presentation1.pptx(pv6)
Merge2013 mwarren-presentation1.pptx(pv6)Merge2013 mwarren-presentation1.pptx(pv6)
Merge2013 mwarren-presentation1.pptx(pv6)
 
Lessons from a Dying CMS
Lessons from a Dying CMSLessons from a Dying CMS
Lessons from a Dying CMS
 
MariaDB - the "new" MySQL is 5 years old and everywhere (LinuxCon Europe 2015)
MariaDB - the "new" MySQL is 5 years old and everywhere (LinuxCon Europe 2015)MariaDB - the "new" MySQL is 5 years old and everywhere (LinuxCon Europe 2015)
MariaDB - the "new" MySQL is 5 years old and everywhere (LinuxCon Europe 2015)
 
What every developer should know about database scalability, PyCon 2010
What every developer should know about database scalability, PyCon 2010What every developer should know about database scalability, PyCon 2010
What every developer should know about database scalability, PyCon 2010
 
MariaDB 10: The Complete Tutorial
MariaDB 10: The Complete TutorialMariaDB 10: The Complete Tutorial
MariaDB 10: The Complete Tutorial
 
Cassandra vs. Redis
Cassandra vs. RedisCassandra vs. Redis
Cassandra vs. Redis
 
Solr Black Belt Pre-conference
Solr Black Belt Pre-conferenceSolr Black Belt Pre-conference
Solr Black Belt Pre-conference
 
Scaling the Web: Databases & NoSQL
Scaling the Web: Databases & NoSQLScaling the Web: Databases & NoSQL
Scaling the Web: Databases & NoSQL
 
Perconalive feb-2011-share
Perconalive feb-2011-sharePerconalive feb-2011-share
Perconalive feb-2011-share
 
Flink Forward San Francisco 2019: Moving from Lambda and Kappa Architectures ...
Flink Forward San Francisco 2019: Moving from Lambda and Kappa Architectures ...Flink Forward San Francisco 2019: Moving from Lambda and Kappa Architectures ...
Flink Forward San Francisco 2019: Moving from Lambda and Kappa Architectures ...
 
Scalding by Adform Research, Alex Gryzlov
Scalding by Adform Research, Alex GryzlovScalding by Adform Research, Alex Gryzlov
Scalding by Adform Research, Alex Gryzlov
 

Plus de fulin tang (10)

一个Nosql的故事
一个Nosql的故事一个Nosql的故事
一个Nosql的故事
 
新浪微博开放平台中的 Redis 实践
新浪微博开放平台中的 Redis 实践新浪微博开放平台中的 Redis 实践
新浪微博开放平台中的 Redis 实践
 
Redis 坑
Redis 坑Redis 坑
Redis 坑
 
音乐搜索的极致
音乐搜索的极致音乐搜索的极致
音乐搜索的极致
 
基于Lucene的站内搜索 Beta
基于Lucene的站内搜索 Beta基于Lucene的站内搜索 Beta
基于Lucene的站内搜索 Beta
 
基于 lucene 的站内搜索
基于 lucene 的站内搜索基于 lucene 的站内搜索
基于 lucene 的站内搜索
 
Voldemort Intro Tangfl
Voldemort Intro TangflVoldemort Intro Tangfl
Voldemort Intro Tangfl
 
基于Lucene的站内搜索
基于Lucene的站内搜索基于Lucene的站内搜索
基于Lucene的站内搜索
 
基于Lucene的站内搜索
基于Lucene的站内搜索基于Lucene的站内搜索
基于Lucene的站内搜索
 
毕业设计-Slide
毕业设计-Slide毕业设计-Slide
毕业设计-Slide
 

Gizzard, DAL and more