SlideShare une entreprise Scribd logo
1  sur  14
Télécharger pour lire hors ligne
Lightning Introduction
to Cassandra

Michaël Figuière
@mfiguiere
Speaker

                 Michaël Figuière




                      @mfiguiere


©2012 DataStax                      2
Ring Architecture


                        Node     Node




                 Node     Cassandra     Node




                        Node
                                Node




©2012 DataStax                                 3
Ring Architecture


                         Node     Replica




                 Node
                                            Replica




                        Node
                                Replica




©2012 DataStax                                        4
Linear Scalability
                 Client Writes/s by Node Count - Replication Factor = 3




©2012 DataStax                                                            5
Client / Server Communication

          Client   ?           Node     Replica



          Client

                       Node
                                                  Replica
          Client


                              Node
          Client                      Replica




©2012 DataStax                                              6
Client / Server Communication

          Client           Node         Replica



          Client

                   Node
                                                  Replica
          Client


                          Node
          Client                      Replica




                   Coordinator node:
                   Forwards all R/W requests
                   to corresponding replicas
©2012 DataStax                                              7
Request Path
                       1
          Client                   Node             Replica
                                              2

                                                   3
          Client
                   4                                    2
                           Node
                                                              Replica
                                                        3
          Client
                                                    2
                                          3
                                  Node
          Client                                  Replica




                           Coordinator node

©2012 DataStax                                                          8
Column Family Data Model


                             name        email         address    state
                  jbellis
                            Jonathan   jb@ds.com      123 main    TX
                             name        email         address    state
                  dhutch
                             Daria     dh@ds.com      45 2nd st   CA
                             name        email
                 egilmore
                              Eric     eg@ds.com


                 Row Key                         Columns




©2012 DataStax                                                            9
Column Family Data Model


                            dhutch     egilmore    datastax   mzcassie
                  jbellis

                            egilmore
                  dhutch

                            datastax   mzcassie
                 egilmore



                 Row Key                     Columns




©2012 DataStax                                                           10
CQL3 Data Model
    Timeline Table
         user_id     tweet_id      author                       body
         gmason        1765        phenry      Give me liberty or give me death
         gmason        1742      gwashington   I chopped down the cherry tree
       ahamilton       1797        jadams      A government of laws, not men
       ahamilton       1742      gwashington   I chopped down the cherry tree

       Partition     Remaining
         Key           Key




©2012 DataStax                                                                    11
CQL3 Data Model
    Timeline Table
         user_id     tweet_id     author                       body
         gmason        1765       phenry      Give me liberty or give me death
         gmason        1742     gwashington   I chopped down the cherry tree
       ahamilton       1797       jadams      A government of laws, not men
       ahamilton       1742     gwashington   I chopped down the cherry tree


    CQL
                   CREATE TABLE timeline (
                            user_id varchar,
                            tweet_id uuid,
                            author varchar,
                            body varchar,
                            PRIMARY KEY (user_id, tweet_id));


©2012 DataStax                                                                   12
CQL3 Data Model
    Timeline Table
         user_id         tweet_id        author                            body
         gmason            1765          phenry       Give me liberty or give me death
         gmason            1742        gwashington    I chopped down the cherry tree
       ahamilton           1797          jadams       A government of laws, not men
       ahamilton           1742        gwashington    I chopped down the cherry tree



Timeline Physical Layout
                 [1742, author]       [1742, body]        [1765, author]          [1765, body]
   gmason
                 gwashington      I chopped down the...      phenry        Give me liberty or give...
                 [1742, author]       [1742, body]        [1797, author]          [1797, body]
 ahamilton
                 gwashington      I chopped down the...      jadams        A government of laws...


©2012 DataStax                                                                                          13
Stay Tuned!

          blog.datastax.com
          @mfiguiere

Contenu connexe

En vedette

Conding Dojo Fruit Shop
Conding Dojo Fruit ShopConding Dojo Fruit Shop
Conding Dojo Fruit ShopDuchess France
 
An Introduction to Cassandra - Oracle User Group
An Introduction to Cassandra - Oracle User GroupAn Introduction to Cassandra - Oracle User Group
An Introduction to Cassandra - Oracle User GroupCarlos Juzarte Rolo
 
Gemfire Sqlfire - La Marmite NoSql
Gemfire Sqlfire - La Marmite NoSqlGemfire Sqlfire - La Marmite NoSql
Gemfire Sqlfire - La Marmite NoSqlDuchess France
 
An Introduction To Cassandra
An Introduction To CassandraAn Introduction To Cassandra
An Introduction To CassandraEric Evans
 
An Introduction to Apache Cassandra
An Introduction to Apache CassandraAn Introduction to Apache Cassandra
An Introduction to Apache CassandraSaeid Zebardast
 

En vedette (6)

Hands-On Apache Spark
Hands-On Apache SparkHands-On Apache Spark
Hands-On Apache Spark
 
Conding Dojo Fruit Shop
Conding Dojo Fruit ShopConding Dojo Fruit Shop
Conding Dojo Fruit Shop
 
An Introduction to Cassandra - Oracle User Group
An Introduction to Cassandra - Oracle User GroupAn Introduction to Cassandra - Oracle User Group
An Introduction to Cassandra - Oracle User Group
 
Gemfire Sqlfire - La Marmite NoSql
Gemfire Sqlfire - La Marmite NoSqlGemfire Sqlfire - La Marmite NoSql
Gemfire Sqlfire - La Marmite NoSql
 
An Introduction To Cassandra
An Introduction To CassandraAn Introduction To Cassandra
An Introduction To Cassandra
 
An Introduction to Apache Cassandra
An Introduction to Apache CassandraAn Introduction to Apache Cassandra
An Introduction to Apache Cassandra
 

Plus de Duchess France

Intro - La Marmite NoSql
Intro - La Marmite NoSqlIntro - La Marmite NoSql
Intro - La Marmite NoSqlDuchess France
 
2 ans de Duchess France - Ouverture
2 ans de Duchess France - Ouverture2 ans de Duchess France - Ouverture
2 ans de Duchess France - OuvertureDuchess France
 
Design poo togo_jug_final
Design poo togo_jug_finalDesign poo togo_jug_final
Design poo togo_jug_finalDuchess France
 
Duchess advice events_september2011
Duchess advice events_september2011Duchess advice events_september2011
Duchess advice events_september2011Duchess France
 
Presentation anniversaire duchess
Presentation anniversaire duchessPresentation anniversaire duchess
Presentation anniversaire duchessDuchess France
 

Plus de Duchess France (8)

Intro - La Marmite NoSql
Intro - La Marmite NoSqlIntro - La Marmite NoSql
Intro - La Marmite NoSql
 
2 ans de Duchess France - Ouverture
2 ans de Duchess France - Ouverture2 ans de Duchess France - Ouverture
2 ans de Duchess France - Ouverture
 
Ces nanas qui codent
Ces nanas qui codentCes nanas qui codent
Ces nanas qui codent
 
Design poo togo_jug_final
Design poo togo_jug_finalDesign poo togo_jug_final
Design poo togo_jug_final
 
Duchess advice events_september2011
Duchess advice events_september2011Duchess advice events_september2011
Duchess advice events_september2011
 
Trivial Java - Part 2
Trivial Java - Part 2Trivial Java - Part 2
Trivial Java - Part 2
 
Trivial Java - Part 1
Trivial Java - Part 1Trivial Java - Part 1
Trivial Java - Part 1
 
Presentation anniversaire duchess
Presentation anniversaire duchessPresentation anniversaire duchess
Presentation anniversaire duchess
 

Dernier

Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 

Dernier (20)

Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 

Data stax - lightning introduction to cassandra - Marmite NoSql

  • 2. Speaker Michaël Figuière @mfiguiere ©2012 DataStax 2
  • 3. Ring Architecture Node Node Node Cassandra Node Node Node ©2012 DataStax 3
  • 4. Ring Architecture Node Replica Node Replica Node Replica ©2012 DataStax 4
  • 5. Linear Scalability Client Writes/s by Node Count - Replication Factor = 3 ©2012 DataStax 5
  • 6. Client / Server Communication Client ? Node Replica Client Node Replica Client Node Client Replica ©2012 DataStax 6
  • 7. Client / Server Communication Client Node Replica Client Node Replica Client Node Client Replica Coordinator node: Forwards all R/W requests to corresponding replicas ©2012 DataStax 7
  • 8. Request Path 1 Client Node Replica 2 3 Client 4 2 Node Replica 3 Client 2 3 Node Client Replica Coordinator node ©2012 DataStax 8
  • 9. Column Family Data Model name email address state jbellis Jonathan jb@ds.com 123 main TX name email address state dhutch Daria dh@ds.com 45 2nd st CA name email egilmore Eric eg@ds.com Row Key Columns ©2012 DataStax 9
  • 10. Column Family Data Model dhutch egilmore datastax mzcassie jbellis egilmore dhutch datastax mzcassie egilmore Row Key Columns ©2012 DataStax 10
  • 11. CQL3 Data Model Timeline Table user_id tweet_id author body gmason 1765 phenry Give me liberty or give me death gmason 1742 gwashington I chopped down the cherry tree ahamilton 1797 jadams A government of laws, not men ahamilton 1742 gwashington I chopped down the cherry tree Partition Remaining Key Key ©2012 DataStax 11
  • 12. CQL3 Data Model Timeline Table user_id tweet_id author body gmason 1765 phenry Give me liberty or give me death gmason 1742 gwashington I chopped down the cherry tree ahamilton 1797 jadams A government of laws, not men ahamilton 1742 gwashington I chopped down the cherry tree CQL CREATE TABLE timeline ( user_id varchar, tweet_id uuid, author varchar, body varchar, PRIMARY KEY (user_id, tweet_id)); ©2012 DataStax 12
  • 13. CQL3 Data Model Timeline Table user_id tweet_id author body gmason 1765 phenry Give me liberty or give me death gmason 1742 gwashington I chopped down the cherry tree ahamilton 1797 jadams A government of laws, not men ahamilton 1742 gwashington I chopped down the cherry tree Timeline Physical Layout [1742, author] [1742, body] [1765, author] [1765, body] gmason gwashington I chopped down the... phenry Give me liberty or give... [1742, author] [1742, body] [1797, author] [1797, body] ahamilton gwashington I chopped down the... jadams A government of laws... ©2012 DataStax 13
  • 14. Stay Tuned! blog.datastax.com @mfiguiere