SlideShare une entreprise Scribd logo
1  sur  35
Introduction to
Couchbase Server 2.0


        Dipti Borkar
        Director, Product Management




                                   1
Couchbase Server


    NoSQL Document
    Database
                   2.0


                         2
Couchbase Server


             Easy                             Consistent High
           Scalability                         Performance
      Grow cluster without          Consistent sub-millisecond
   application changes, without   read and write response times
   downtime with a single click   with consistent high throughput


             Always                            Flexible Data
               On                   JSON
                                  JSON JSO
                                   JSON
                                   JSON
                                          N

                                                  Model
             24x365
   No downtime for software           JSON document model with
      upgrades, hardware                   no fixed schema.
       maintenance, etc.

                                                                    3
Flexible Data Model


                         {
                             “ID”: 1,
                             “FIRST”: “Dipti”,
                             “LAST”: “Borkar”,
                             “ZIP”: “94040”,
                             “CITY”: “MV”,
                             “STATE”: “CA”
                         }                               JSON   JSON
                                                  JSON
                                           JSON


      • No need to worry about the database when changing your
        application
      • Records can have different structures, there is no fixed
        schema
      • Allows painless data model changes for rapid application
        development

                                                                       4
New in 2.0


      JSON support         Indexing and Querying


            JSON
          JSON JSO
             JSON N
             JSON




  Incremental Map Reduce   Cross data center replication




                                                           5
Couchbase Server 2.0 Architecture
   8092                 11211             11210
   Query API            Memcapable 1.0    Memcapable 2.0



                          Moxi
      Query Engine




                                                              REST management API/Web UI




                                                                                                                                                                                                                                vBucket state and replication manager
                                Memcached




                                                                                                                                                 Global singleton supervisor


                                                                                                                                                                                Rebalance orchestrator
                                                                                                                         Configuration manager




                                                                                                                                                                                                          Node health monitor
                                                                                                       Process monitor
                                                                                           Heartbeat
                          Couchbase EP Engine
                     Data Manager                                               Cluster Manager
                                         storage interface




                     New Persistence Layer                   http                               on each node                                                                   one per cluster



                                                                                                                     Erlang/OTP



                                                             HTTP                            Erlang port mapper                                                                                          Distributed Erlang
                                                             8091                            4369                                                                                                        21100 - 21199
                                                                                                                                                                                                                                                                        6
Couchbase Server 2.0 Architecture
   8092                 11211             11210
   Query API            Memcapable 1.0    Memcapable 2.0



                          Moxi
      Query Engine




                                                              REST management API/Web UI




                                                                                                                                                                                                                                vBucket state and replication manager
                          Object-level Cache




                                                                                                                                                 Global singleton supervisor


                                                                                                                                                                                Rebalance orchestrator
                                                                                                                         Configuration manager




                                                                                                                                                                                                          Node health monitor
                                                                                                       Process monitor
                                                                                           Heartbeat
                          Couchbase EP Engine

                                         storage interface




                     New Persistence Layer                   http                               on each node                                                                   one per cluster



                                                                                                                     Erlang/OTP



                                                             HTTP                            Erlang port mapper                                                                                          Distributed Erlang
                                                             8091                            4369                                                                                                        21100 - 21199
                                                                                                                                                                                                                                                                        7
Couchbase deployment


                   Web
                 Application

                  Couchbase
                 Client Library

   Data Flow




                                  Cluster Management


                                                       8
COUCHBASE OPERATIONS




                       9
Single node - Couchbase Write Operation
                                                    2

                                            Doc 1
                    App Server




                                       3           2        3
                                      Managed Cache
   To other node   Replication
                                            Doc 1
                     Queue




                                                                Disk Queue
                             Disk




                                    Couchbase Server Node                    10
Single node - Couchbase Update Operation
                                                     2

                                            Doc 1’
                    App Server




                                       3           2        3
                                      Managed Cache
   To other node   Replication
                                                1
                                            Doc 1’
                     Queue




                                                                Disk Queue
                             Disk
                                            Doc 1




                                    Couchbase Server Node                    11
Single node - Couchbase Read Operation
                                                    2




                                            Doc 1
                                             GET
                    App Server




                                       3           2        3
                                      Managed Cache
   To other node   Replication
                     Queue                  Doc 1




                                                                Disk Queue
                             Disk
                                            Doc 1




                                    Couchbase Server Node                    12
Single node - Couchbase Cache Eviction
                                                                     2

                                                         Doc 6
                                                             2
                                                             3
                                                             4
                                                             5
                    App Server




                                             3           2                3
                                            Managed Cache
   To other node   Replication
                                                         Doc 1
                     Queue




                                                                              Disk Queue
                             Disk
                                                         Doc 1


                                 Doc 6   Doc 5   Doc 4    Doc 3   Doc 2




                                         Couchbase Server Node                             13
Single node – Couchbase Cache Miss
                                                                     2




                                                         Doc 1
                                                          GET
                    App Server




                                             3           2                  3
                                            Managed Cache
   To other node   Replication
                     Queue                               Doc 1
                                          Doc 5 4 4
                                            Doc
                                              Doc                 Doc 3 2
                                                                    Doc




                                                                                Disk Queue
                             Disk
                                                         Doc 1


                                 Doc 6   Doc 5   Doc 4    Doc 3   Doc 2




                                         Couchbase Server Node                               14
Cluster wide - Basic Operation

                  APP SERVER 1                               APP SERVER 2
            COUCHBASE Client Library                    COUCHBASE Client Library
                    CLUSTER MAP                              CLUSTER MAP



                             READ/WRITE/UPDATE

               SERVER 1                     SERVER 2                 SERVER 3      • Docs distributed evenly across
                ACTIVE                       ACTIVE                   ACTIVE
                                                                                     servers

            Doc 5      Doc                Doc 4   Doc              Doc 1    Doc    • Each server stores both active and
                                                                                     replica docs
            Doc 2      Doc                Doc 7   Doc              Doc 2    Doc      Only one server active at a time

                                                                                   • Client library provides app with
            Doc 9      Doc                Doc 8   Doc              Doc 6    Doc
                                                                                     simple interface to database
                REPLICA                      REPLICA                  REPLICA      • Cluster map provides map
                                                                                     to which server doc is on
            Doc 4      Doc                Doc 6   Doc              Doc 7    Doc      App never needs to know

            Doc 1      Doc                Doc 3   Doc              Doc 9    Doc    • App reads, writes, updates docs

            Doc 8      Doc                Doc 2   Doc              Doc 5    Doc    • Multiple app servers can access same
                                                                                     document at same time
                                    COUCHBASE SERVER CLUSTER


User Configured Replica Count = 1
                                                                                                                        15
Cluster wide - Add Nodes to Cluster

                       APP SERVER 1                                   APP SERVER 2
                 COUCHBASE Client Library                         COUCHBASE Client Library
                         CLUSTER MAP                                   CLUSTER MAP


                                READ/WRITE/UPDATE                                    READ/WRITE/UPDATE


      SERVER 1                      SERVER 2           SERVER 3               SERVER 4          SERVER 5   • Two servers added
       ACTIVE                       ACTIVE              ACTIVE                 ACTIVE           ACTIVE
                                                                                                             One-click operation

   Doc 5      Doc             Doc 4       Doc        Doc 1   Doc                                           • Docs automatically
                                                                                                             rebalanced across
   Doc 2      Doc             Doc 7       Doc        Doc 2   Doc                                             cluster
                                                                                                             Even distribution of docs
                                                                                                             Minimum doc movement
   Doc 9      Doc             Doc 8       Doc        Doc 6   Doc
                                                                                                           • Cluster map updated
       REPLICA                      REPLICA             REPLICA               REPLICA           REPLICA
                                                                                                           • App database
   Doc 4      Doc             Doc 6       Doc        Doc 7   Doc                                             calls now distributed
                                                                                                             over larger number of
   Doc 1      Doc             Doc 3       Doc        Doc 9   Doc                                             servers
   Doc 8      Doc             Doc 2       Doc        Doc 5   Doc


                                               COUCHBASE SERVER CLUSTER


User Configured Replica Count = 1
                                                                                                                                    16
Cluster wide - Fail Over Node

                         APP SERVER 1                                 APP SERVER 2
                   COUCHBASE Client Library                       COUCHBASE Client Library
                          CLUSTER MAP                                  CLUSTER MAP




        SERVER 1                    SERVER 2           SERVER 3               SERVER 4         SERVER 5    • App servers accessing docs
         ACTIVE                     ACTIVE              ACTIVE                 ACTIVE           ACTIVE
                                                                                                           • Requests to Server 3 fail
    Doc 5       Doc             Doc 4     Doc        Doc 1   Doc           Doc 9     Doc     Doc 6   Doc
                                                                                                           • Cluster detects server failed
                                                                                                             Promotes replicas of docs to
    Doc 2       Doc             Doc 7     Doc        Doc 2   Doc           Doc 8     Doc             Doc     active
                                                                                                             Updates cluster map
    Doc 1                       Doc 3
                                                                                                           • Requests for docs now go to
        REPLICA                     REPLICA             REPLICA               REPLICA           REPLICA      appropriate server

    Doc 4       Doc            Doc 6      Doc        Doc 7   Doc           Doc 5     Doc     Doc 8   Doc   • Typically rebalance
                                                                                                             would follow
    Doc 1       Doc            Doc 3      Doc        Doc 9   Doc           Doc 2                     Doc




                                               COUCHBASE SERVER CLUSTER


User Configured Replica Count = 1
                                                                                                                                            17
DEMO TIME




            18
Indexing and Querying – The basics

 • Define materialized views on JSON documents and
   then query across the data set
 • Using views you can define
     •   Primary indexes
     •   Simple secondary indexes (most common use case)
     •   Complex secondary, tertiary and composite indexes
     •   Aggregations (reduction)
 • Indexes are eventually indexed
 • Queries are eventually consistent with respect to
   documents
 • Built using Map/Reduce technology
     • Map and Reduce functions are written in Javascript
                                                             19
Eventually indexed Views – Data flow
                                                               2

                                                       Doc 1
                       App Server



                   Couchbase Server Node
                                              3          2         3
                                             Managed Cache
   To other node    Replication
                    Queue                          Doc 1




                                                                       Disk Queue
                                  Disk
                                                       Doc 1




                                         View engine

                                                                                    20
Cluster wide - Indexing and Querying

                  APP SERVER 1                                APP SERVER 2
            COUCHBASE Client Library                     COUCHBASE Client Library
                    CLUSTER MAP                               CLUSTER MAP



                                                                         Query

           SERVER 1                             SERVER 2                             SERVER 3   • Indexing work is distributed
           ACTIVE                              ACTIVE                               ACTIVE
                                                                                                  amongst nodes

      Doc 5       Doc                       Doc 5    Doc                      Doc 5      Doc    • Large data set possible

      Doc 2       Doc                       Doc 2    Doc                      Doc 2      Doc
                                                                                                • Parallelize the effort

      Doc 9       Doc
                                                                                                • Each node has index for data stored
                                            Doc 9    Doc                      Doc 9      Doc
                                                                                                  on it
          REPLICA                              REPLICA                              REPLICA     • Queries combine the results from
      Doc 4      Doc
                                                                                                  required nodes
                                            Doc 4   Doc                       Doc 4      Doc

      Doc 1      Doc                        Doc 1   Doc                       Doc 1      Doc

      Doc 8      Doc                        Doc 8   Doc                       Doc 8      Doc

                                    COUCHBASE SERVER CLUSTER


User Configured Replica Count = 1
                                                                                                                                 21
Cross Data Center Replication – The basics

• Replicate your Couchbase data across clusters
• Clusters may be spread across geos
• Configured on a per-bucket basis
• Supports unidirectional and bidirectional operation
• Application can read and write from both clusters
  (active – active replication)
• Replication throughput scales out linearly
• Different from intra-cluster replication



                                                        22
Cross data center replication – Data flow
                                                   2

                                           Doc 1
                      App Server



                   Couchbase Server Node
                                       3           2    3
                                      Managed Cache
   To other node     Replication
                                           Doc 1
                       Queue




                                                            Disk Queue
                               Disk
                                           Doc 1




                                           XDCR Queue
                                                        To other cluster
                                                                           23
Cluster wide - XDCR
      SERVER 1                SERVER 2                            SERVER 3
                 ACTIVE                  ACTIVE                              ACTIVE                COUCHBASE SERVER CLUSTER
            Doc                     Doc                                  Doc                            NY DATA CENTER

           Doc 2                    Doc                                  Doc

           Doc 9                    Doc                                  Doc
RAM                         RAM                              RAM


  Doc       Doc       Doc     Doc    Doc      Doc                Doc     Doc     Doc

           DISK                     DISK                                DISK



                                                  SERVER 1                            SERVER 2                  SERVER 3
                                                             ACTIVE                              ACTIVE                    ACTIVE

                                                        Doc                                 Doc                        Doc

                                                        Doc 2                               Doc                        Doc

                                                        Doc 9                               Doc                        Doc
                                           RAM                                 RAM                           RAM


        COUCHBASE SERVER CLUSTER                  Doc    Doc      Doc                 Doc    Doc      Doc       Doc    Doc     Doc
             SF DATA CENTER
                                                        DISK                                DISK                      DISK          24
DEMO TIME




            25
Demo: The next big social game


  3 Objects (documents) within game:
       • Players
       • Monsters
       • Items

  Gameplay:
      • Players fight monsters
      • Monsters drop items
      • Players own items
                                       26
Player Document


  {
      "jsonType": "player",
      "uuid": "35767d02-a958-4b83-8179-616816692de1",
      "name": "Keith4540",
      "hitpoints": 75,
                                Player ID
      "experience": 663,
      "level": 4,
      "loggedIn": false
  }


                                                        27
Item Document


 {
                                      Item ID
      "jsonType": "item",
      "name": "Katana_e5890c94-11c6-65746ce6c560",
      "uuid": "e5890c94-11c6-4856-a7a6-65746ce6c560",
      "ownerId": "Dale9887"
 }
                              Player ID




                                                        28
Monster Document


 {
      "jsonType": "monster",              Monster ID
      "name": "Bauchan9932",
      "uuid": "d10dfc1b-0412-4140-b4ec-affdbf2aa5ec",
      "hitpoints": 370,
      "experienceWhenKilled": 52,
      "itemProbability": 0.5050581341872865
 }



                                                        29
GAME ON!




           30
Full Text Search Integration
• Elastic Search is good for ad-hoc queries and faceted browsing
• Couchbase adapter uses XDCR to push mutations to ESDocs
  are indexed by Elastic Search
• Couchbase ES Adapter is cluster-aware




                                           ElasticSearch



       Unidirectional Cross Data Center Replication
                                                               31
Full Text Search




                                         Application Server
                                  Couchbase SDK                ES Queries over HTTP

                                                                                  Do
                            ta                                       TS              c
                         Da                       ery                     Qu             Re
                                               Qu                           er             fs
                                         M   R                                y


        Couchbase Server Cluster                                              ElasticSearch Server Cluster




          MR      MR              MR             MR
         Views   Views           Views          Views



                                                                                                  XDCR-based
                                              Cross Data Center Replication                      CB-ES Transport



                                                                                                                   32
Couchbase SDKs



Java SDK             User Code


.Net SDK            Java client API
                                          CouchbaseClient cb = new CouchbaseClient(listURIs,
                                          "aBucket", "letmein");

                                          cb.set("hello", 0, "world");
                                          cb.get("hello");
                 Couchbase Java Library
PHP SDK            (spymemcached)


Ruby SDK
             Couchbase Server
…and many
more

            http://www.couchbase.com/develop
                                                                                               33
QUESTIONS?




             34 3
THANK YOU

DIPTI@COUCBASE.COM
     @DBORKAR




                     35 3

Contenu connexe

En vedette

Evaluating NoSQL Performance: Time for Benchmarking
Evaluating NoSQL Performance: Time for BenchmarkingEvaluating NoSQL Performance: Time for Benchmarking
Evaluating NoSQL Performance: Time for Benchmarking
Sergey Bushik
 
Benchmarking MongoDB and CouchBase
Benchmarking MongoDB and CouchBaseBenchmarking MongoDB and CouchBase
Benchmarking MongoDB and CouchBase
Christopher Choi
 
Lightning Talk: Erlang on Xen - Mikhail Bortnyk
Lightning Talk: Erlang on Xen - Mikhail BortnykLightning Talk: Erlang on Xen - Mikhail Bortnyk
Lightning Talk: Erlang on Xen - Mikhail Bortnyk
Elixir Club
 
The mystique of erlang
The mystique of erlangThe mystique of erlang
The mystique of erlang
Carob Cherub
 
Erlang Practice
Erlang PracticeErlang Practice
Erlang Practice
litaocheng
 

En vedette (20)

Couchbase Performance Benchmarking
Couchbase Performance BenchmarkingCouchbase Performance Benchmarking
Couchbase Performance Benchmarking
 
Evaluating NoSQL Performance: Time for Benchmarking
Evaluating NoSQL Performance: Time for BenchmarkingEvaluating NoSQL Performance: Time for Benchmarking
Evaluating NoSQL Performance: Time for Benchmarking
 
Methods of NoSQL database systems benchmarking
Methods of NoSQL database systems benchmarkingMethods of NoSQL database systems benchmarking
Methods of NoSQL database systems benchmarking
 
Benchmarking MongoDB and CouchBase
Benchmarking MongoDB and CouchBaseBenchmarking MongoDB and CouchBase
Benchmarking MongoDB and CouchBase
 
Erlang Concurrency
Erlang ConcurrencyErlang Concurrency
Erlang Concurrency
 
Lightning Talk: Erlang on Xen - Mikhail Bortnyk
Lightning Talk: Erlang on Xen - Mikhail BortnykLightning Talk: Erlang on Xen - Mikhail Bortnyk
Lightning Talk: Erlang on Xen - Mikhail Bortnyk
 
The mystique of erlang
The mystique of erlangThe mystique of erlang
The mystique of erlang
 
Why erlang
Why erlangWhy erlang
Why erlang
 
Erlang on OSv
Erlang on OSvErlang on OSv
Erlang on OSv
 
Erlang Developments: The Good, The Bad and The Ugly
Erlang Developments: The Good, The Bad and The UglyErlang Developments: The Good, The Bad and The Ugly
Erlang Developments: The Good, The Bad and The Ugly
 
Exception Handler, Controller Advice Of Spring
Exception Handler, Controller Advice Of SpringException Handler, Controller Advice Of Spring
Exception Handler, Controller Advice Of Spring
 
Intro to Erlang
Intro to ErlangIntro to Erlang
Intro to Erlang
 
Erlang For Five Nines
Erlang For Five NinesErlang For Five Nines
Erlang For Five Nines
 
An introduction to erlang
An introduction to erlangAn introduction to erlang
An introduction to erlang
 
Erlang Practice
Erlang PracticeErlang Practice
Erlang Practice
 
learn you some erlang - chap 9 to chap10
learn you some erlang - chap 9 to chap10learn you some erlang - chap 9 to chap10
learn you some erlang - chap 9 to chap10
 
Erlang OTP
Erlang OTPErlang OTP
Erlang OTP
 
Intro To Erlang
Intro To ErlangIntro To Erlang
Intro To Erlang
 
Deep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDBDeep Dive: Amazon DynamoDB
Deep Dive: Amazon DynamoDB
 
Actors in erlang
Actors in erlangActors in erlang
Actors in erlang
 

Similaire à Introduction to Couchbase Server 2.0

O connor bosc2010
O connor bosc2010O connor bosc2010
O connor bosc2010
BOSC 2010
 
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
Ontico
 
Session 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky NoteSession 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky Note
ISSGC Summer School
 
Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical
ISSGC Summer School
 
Transition from relational to NoSQL Philly DAMA Day
Transition from relational to NoSQL Philly DAMA DayTransition from relational to NoSQL Philly DAMA Day
Transition from relational to NoSQL Philly DAMA Day
Dipti Borkar
 
Net flowhadoop flocon2013_yhlee_final
Net flowhadoop flocon2013_yhlee_finalNet flowhadoop flocon2013_yhlee_final
Net flowhadoop flocon2013_yhlee_final
Yeounhee Lee
 

Similaire à Introduction to Couchbase Server 2.0 (20)

O connor bosc2010
O connor bosc2010O connor bosc2010
O connor bosc2010
 
What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?
 
WebLogic Diagnostic Framework Dr. Frank Munz / munz & more WLS11g
WebLogic Diagnostic Framework  Dr. Frank Munz / munz & more WLS11gWebLogic Diagnostic Framework  Dr. Frank Munz / munz & more WLS11g
WebLogic Diagnostic Framework Dr. Frank Munz / munz & more WLS11g
 
Couchbase b jmeetup
Couchbase b jmeetupCouchbase b jmeetup
Couchbase b jmeetup
 
cosbench-openstack.pdf
cosbench-openstack.pdfcosbench-openstack.pdf
cosbench-openstack.pdf
 
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
Shared personalization service. How to scale to 15 k rps (Patrice Pelland)
 
BUG - BEA Users\' Group, Jan16 2003
BUG - BEA Users\' Group, Jan16 2003BUG - BEA Users\' Group, Jan16 2003
BUG - BEA Users\' Group, Jan16 2003
 
Exchange Server 2013 Architecture Deep Dive, Part 1
Exchange Server 2013 Architecture Deep Dive, Part 1Exchange Server 2013 Architecture Deep Dive, Part 1
Exchange Server 2013 Architecture Deep Dive, Part 1
 
Couchdb + Membase = Couchbase
Couchdb + Membase = CouchbaseCouchdb + Membase = Couchbase
Couchdb + Membase = Couchbase
 
OpenStack Dragonflow shenzhen and Hangzhou meetups
OpenStack Dragonflow shenzhen and Hangzhou  meetupsOpenStack Dragonflow shenzhen and Hangzhou  meetups
OpenStack Dragonflow shenzhen and Hangzhou meetups
 
Big Data Israel Meetup : Couchbase and Big Data
Big Data Israel Meetup : Couchbase and Big DataBig Data Israel Meetup : Couchbase and Big Data
Big Data Israel Meetup : Couchbase and Big Data
 
Session 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky NoteSession 49 Practical Semantic Sticky Note
Session 49 Practical Semantic Sticky Note
 
Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical Session 49 - Semantic metadata management practical
Session 49 - Semantic metadata management practical
 
What Multisite Means for Identity Management
What Multisite Means for Identity ManagementWhat Multisite Means for Identity Management
What Multisite Means for Identity Management
 
Navigating the Transition from relational to NoSQL - CloudCon Expo 2012
Navigating the Transition from relational to NoSQL - CloudCon Expo 2012Navigating the Transition from relational to NoSQL - CloudCon Expo 2012
Navigating the Transition from relational to NoSQL - CloudCon Expo 2012
 
Transition from relational to NoSQL Philly DAMA Day
Transition from relational to NoSQL Philly DAMA DayTransition from relational to NoSQL Philly DAMA Day
Transition from relational to NoSQL Philly DAMA Day
 
The Very Very Latest in Database Development - Oracle Open World 2012
The Very Very Latest in Database Development - Oracle Open World 2012The Very Very Latest in Database Development - Oracle Open World 2012
The Very Very Latest in Database Development - Oracle Open World 2012
 
The Very Very Latest In Database Development - Lucas Jellema - Oracle OpenWor...
The Very Very Latest In Database Development - Lucas Jellema - Oracle OpenWor...The Very Very Latest In Database Development - Lucas Jellema - Oracle OpenWor...
The Very Very Latest In Database Development - Lucas Jellema - Oracle OpenWor...
 
Spark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 WorkshopSpark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 Workshop
 
Net flowhadoop flocon2013_yhlee_final
Net flowhadoop flocon2013_yhlee_finalNet flowhadoop flocon2013_yhlee_final
Net flowhadoop flocon2013_yhlee_final
 

Plus de Dipti Borkar

Introduction to couchbase
Introduction to couchbaseIntroduction to couchbase
Introduction to couchbase
Dipti Borkar
 
How companies-use-no sql-and-couchbase-10152013
How companies-use-no sql-and-couchbase-10152013How companies-use-no sql-and-couchbase-10152013
How companies-use-no sql-and-couchbase-10152013
Dipti Borkar
 
Characteristics of no sql databases
Characteristics of no sql databasesCharacteristics of no sql databases
Characteristics of no sql databases
Dipti Borkar
 
Part 2 of the webinar - Which freaking database should I use?
Part 2 of the webinar - Which freaking database should I use?Part 2 of the webinar - Which freaking database should I use?
Part 2 of the webinar - Which freaking database should I use?
Dipti Borkar
 

Plus de Dipti Borkar (15)

Presto – Today and Beyond – The Open Source SQL Engine for Querying all Data...
Presto – Today and Beyond – The Open Source SQL Engine for Querying all Data...Presto – Today and Beyond – The Open Source SQL Engine for Querying all Data...
Presto – Today and Beyond – The Open Source SQL Engine for Querying all Data...
 
Couchbase 101
Couchbase 101 Couchbase 101
Couchbase 101
 
Revolutionizing the customer experience - Hello Engagement Database
Revolutionizing the customer experience - Hello Engagement DatabaseRevolutionizing the customer experience - Hello Engagement Database
Revolutionizing the customer experience - Hello Engagement Database
 
How companies use NoSQL & Couchbase - NoSQL Now 2014
How companies use NoSQL & Couchbase - NoSQL Now 2014How companies use NoSQL & Couchbase - NoSQL Now 2014
How companies use NoSQL & Couchbase - NoSQL Now 2014
 
Introduction to couchbase
Introduction to couchbaseIntroduction to couchbase
Introduction to couchbase
 
How companies-use-no sql-and-couchbase-10152013
How companies-use-no sql-and-couchbase-10152013How companies-use-no sql-and-couchbase-10152013
How companies-use-no sql-and-couchbase-10152013
 
Characteristics of no sql databases
Characteristics of no sql databasesCharacteristics of no sql databases
Characteristics of no sql databases
 
How companies use NoSQL and Couchbase - NoSQL Now 2013
How companies use NoSQL and Couchbase - NoSQL Now 2013How companies use NoSQL and Couchbase - NoSQL Now 2013
How companies use NoSQL and Couchbase - NoSQL Now 2013
 
How companies use NoSQL and Couchbase
How companies use NoSQL and CouchbaseHow companies use NoSQL and Couchbase
How companies use NoSQL and Couchbase
 
Part 2 of the webinar - Which freaking database should I use?
Part 2 of the webinar - Which freaking database should I use?Part 2 of the webinar - Which freaking database should I use?
Part 2 of the webinar - Which freaking database should I use?
 
Couchbase Server 2.0 - XDCR - Deep dive
Couchbase Server 2.0 - XDCR - Deep diveCouchbase Server 2.0 - XDCR - Deep dive
Couchbase Server 2.0 - XDCR - Deep dive
 
Couchbase Server 2.0 - Indexing and Querying - Deep dive
Couchbase Server 2.0 - Indexing and Querying - Deep diveCouchbase Server 2.0 - Indexing and Querying - Deep dive
Couchbase Server 2.0 - Indexing and Querying - Deep dive
 
Introduction to NoSQL and Couchbase
Introduction to NoSQL and CouchbaseIntroduction to NoSQL and Couchbase
Introduction to NoSQL and Couchbase
 
Couchbase Server and IBM BigInsights: One + One = Three
Couchbase Server and IBM BigInsights: One + One = ThreeCouchbase Server and IBM BigInsights: One + One = Three
Couchbase Server and IBM BigInsights: One + One = Three
 
Go simple-fast-elastic-with-couchbase-server-borkar
Go simple-fast-elastic-with-couchbase-server-borkarGo simple-fast-elastic-with-couchbase-server-borkar
Go simple-fast-elastic-with-couchbase-server-borkar
 

Dernier

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Dernier (20)

08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 

Introduction to Couchbase Server 2.0

  • 1. Introduction to Couchbase Server 2.0 Dipti Borkar Director, Product Management 1
  • 2. Couchbase Server NoSQL Document Database 2.0 2
  • 3. Couchbase Server Easy Consistent High Scalability Performance Grow cluster without Consistent sub-millisecond application changes, without read and write response times downtime with a single click with consistent high throughput Always Flexible Data On JSON JSON JSO JSON JSON N Model 24x365 No downtime for software JSON document model with upgrades, hardware no fixed schema. maintenance, etc. 3
  • 4. Flexible Data Model { “ID”: 1, “FIRST”: “Dipti”, “LAST”: “Borkar”, “ZIP”: “94040”, “CITY”: “MV”, “STATE”: “CA” } JSON JSON JSON JSON • No need to worry about the database when changing your application • Records can have different structures, there is no fixed schema • Allows painless data model changes for rapid application development 4
  • 5. New in 2.0 JSON support Indexing and Querying JSON JSON JSO JSON N JSON Incremental Map Reduce Cross data center replication 5
  • 6. Couchbase Server 2.0 Architecture 8092 11211 11210 Query API Memcapable 1.0 Memcapable 2.0 Moxi Query Engine REST management API/Web UI vBucket state and replication manager Memcached Global singleton supervisor Rebalance orchestrator Configuration manager Node health monitor Process monitor Heartbeat Couchbase EP Engine Data Manager Cluster Manager storage interface New Persistence Layer http on each node one per cluster Erlang/OTP HTTP Erlang port mapper Distributed Erlang 8091 4369 21100 - 21199 6
  • 7. Couchbase Server 2.0 Architecture 8092 11211 11210 Query API Memcapable 1.0 Memcapable 2.0 Moxi Query Engine REST management API/Web UI vBucket state and replication manager Object-level Cache Global singleton supervisor Rebalance orchestrator Configuration manager Node health monitor Process monitor Heartbeat Couchbase EP Engine storage interface New Persistence Layer http on each node one per cluster Erlang/OTP HTTP Erlang port mapper Distributed Erlang 8091 4369 21100 - 21199 7
  • 8. Couchbase deployment Web Application Couchbase Client Library Data Flow Cluster Management 8
  • 10. Single node - Couchbase Write Operation 2 Doc 1 App Server 3 2 3 Managed Cache To other node Replication Doc 1 Queue Disk Queue Disk Couchbase Server Node 10
  • 11. Single node - Couchbase Update Operation 2 Doc 1’ App Server 3 2 3 Managed Cache To other node Replication 1 Doc 1’ Queue Disk Queue Disk Doc 1 Couchbase Server Node 11
  • 12. Single node - Couchbase Read Operation 2 Doc 1 GET App Server 3 2 3 Managed Cache To other node Replication Queue Doc 1 Disk Queue Disk Doc 1 Couchbase Server Node 12
  • 13. Single node - Couchbase Cache Eviction 2 Doc 6 2 3 4 5 App Server 3 2 3 Managed Cache To other node Replication Doc 1 Queue Disk Queue Disk Doc 1 Doc 6 Doc 5 Doc 4 Doc 3 Doc 2 Couchbase Server Node 13
  • 14. Single node – Couchbase Cache Miss 2 Doc 1 GET App Server 3 2 3 Managed Cache To other node Replication Queue Doc 1 Doc 5 4 4 Doc Doc Doc 3 2 Doc Disk Queue Disk Doc 1 Doc 6 Doc 5 Doc 4 Doc 3 Doc 2 Couchbase Server Node 14
  • 15. Cluster wide - Basic Operation APP SERVER 1 APP SERVER 2 COUCHBASE Client Library COUCHBASE Client Library CLUSTER MAP CLUSTER MAP READ/WRITE/UPDATE SERVER 1 SERVER 2 SERVER 3 • Docs distributed evenly across ACTIVE ACTIVE ACTIVE servers Doc 5 Doc Doc 4 Doc Doc 1 Doc • Each server stores both active and replica docs Doc 2 Doc Doc 7 Doc Doc 2 Doc Only one server active at a time • Client library provides app with Doc 9 Doc Doc 8 Doc Doc 6 Doc simple interface to database REPLICA REPLICA REPLICA • Cluster map provides map to which server doc is on Doc 4 Doc Doc 6 Doc Doc 7 Doc App never needs to know Doc 1 Doc Doc 3 Doc Doc 9 Doc • App reads, writes, updates docs Doc 8 Doc Doc 2 Doc Doc 5 Doc • Multiple app servers can access same document at same time COUCHBASE SERVER CLUSTER User Configured Replica Count = 1 15
  • 16. Cluster wide - Add Nodes to Cluster APP SERVER 1 APP SERVER 2 COUCHBASE Client Library COUCHBASE Client Library CLUSTER MAP CLUSTER MAP READ/WRITE/UPDATE READ/WRITE/UPDATE SERVER 1 SERVER 2 SERVER 3 SERVER 4 SERVER 5 • Two servers added ACTIVE ACTIVE ACTIVE ACTIVE ACTIVE One-click operation Doc 5 Doc Doc 4 Doc Doc 1 Doc • Docs automatically rebalanced across Doc 2 Doc Doc 7 Doc Doc 2 Doc cluster Even distribution of docs Minimum doc movement Doc 9 Doc Doc 8 Doc Doc 6 Doc • Cluster map updated REPLICA REPLICA REPLICA REPLICA REPLICA • App database Doc 4 Doc Doc 6 Doc Doc 7 Doc calls now distributed over larger number of Doc 1 Doc Doc 3 Doc Doc 9 Doc servers Doc 8 Doc Doc 2 Doc Doc 5 Doc COUCHBASE SERVER CLUSTER User Configured Replica Count = 1 16
  • 17. Cluster wide - Fail Over Node APP SERVER 1 APP SERVER 2 COUCHBASE Client Library COUCHBASE Client Library CLUSTER MAP CLUSTER MAP SERVER 1 SERVER 2 SERVER 3 SERVER 4 SERVER 5 • App servers accessing docs ACTIVE ACTIVE ACTIVE ACTIVE ACTIVE • Requests to Server 3 fail Doc 5 Doc Doc 4 Doc Doc 1 Doc Doc 9 Doc Doc 6 Doc • Cluster detects server failed Promotes replicas of docs to Doc 2 Doc Doc 7 Doc Doc 2 Doc Doc 8 Doc Doc active Updates cluster map Doc 1 Doc 3 • Requests for docs now go to REPLICA REPLICA REPLICA REPLICA REPLICA appropriate server Doc 4 Doc Doc 6 Doc Doc 7 Doc Doc 5 Doc Doc 8 Doc • Typically rebalance would follow Doc 1 Doc Doc 3 Doc Doc 9 Doc Doc 2 Doc COUCHBASE SERVER CLUSTER User Configured Replica Count = 1 17
  • 18. DEMO TIME 18
  • 19. Indexing and Querying – The basics • Define materialized views on JSON documents and then query across the data set • Using views you can define • Primary indexes • Simple secondary indexes (most common use case) • Complex secondary, tertiary and composite indexes • Aggregations (reduction) • Indexes are eventually indexed • Queries are eventually consistent with respect to documents • Built using Map/Reduce technology • Map and Reduce functions are written in Javascript 19
  • 20. Eventually indexed Views – Data flow 2 Doc 1 App Server Couchbase Server Node 3 2 3 Managed Cache To other node Replication Queue Doc 1 Disk Queue Disk Doc 1 View engine 20
  • 21. Cluster wide - Indexing and Querying APP SERVER 1 APP SERVER 2 COUCHBASE Client Library COUCHBASE Client Library CLUSTER MAP CLUSTER MAP Query SERVER 1 SERVER 2 SERVER 3 • Indexing work is distributed ACTIVE ACTIVE ACTIVE amongst nodes Doc 5 Doc Doc 5 Doc Doc 5 Doc • Large data set possible Doc 2 Doc Doc 2 Doc Doc 2 Doc • Parallelize the effort Doc 9 Doc • Each node has index for data stored Doc 9 Doc Doc 9 Doc on it REPLICA REPLICA REPLICA • Queries combine the results from Doc 4 Doc required nodes Doc 4 Doc Doc 4 Doc Doc 1 Doc Doc 1 Doc Doc 1 Doc Doc 8 Doc Doc 8 Doc Doc 8 Doc COUCHBASE SERVER CLUSTER User Configured Replica Count = 1 21
  • 22. Cross Data Center Replication – The basics • Replicate your Couchbase data across clusters • Clusters may be spread across geos • Configured on a per-bucket basis • Supports unidirectional and bidirectional operation • Application can read and write from both clusters (active – active replication) • Replication throughput scales out linearly • Different from intra-cluster replication 22
  • 23. Cross data center replication – Data flow 2 Doc 1 App Server Couchbase Server Node 3 2 3 Managed Cache To other node Replication Doc 1 Queue Disk Queue Disk Doc 1 XDCR Queue To other cluster 23
  • 24. Cluster wide - XDCR SERVER 1 SERVER 2 SERVER 3 ACTIVE ACTIVE ACTIVE COUCHBASE SERVER CLUSTER Doc Doc Doc NY DATA CENTER Doc 2 Doc Doc Doc 9 Doc Doc RAM RAM RAM Doc Doc Doc Doc Doc Doc Doc Doc Doc DISK DISK DISK SERVER 1 SERVER 2 SERVER 3 ACTIVE ACTIVE ACTIVE Doc Doc Doc Doc 2 Doc Doc Doc 9 Doc Doc RAM RAM RAM COUCHBASE SERVER CLUSTER Doc Doc Doc Doc Doc Doc Doc Doc Doc SF DATA CENTER DISK DISK DISK 24
  • 25. DEMO TIME 25
  • 26. Demo: The next big social game 3 Objects (documents) within game: • Players • Monsters • Items Gameplay: • Players fight monsters • Monsters drop items • Players own items 26
  • 27. Player Document { "jsonType": "player", "uuid": "35767d02-a958-4b83-8179-616816692de1", "name": "Keith4540", "hitpoints": 75, Player ID "experience": 663, "level": 4, "loggedIn": false } 27
  • 28. Item Document { Item ID "jsonType": "item", "name": "Katana_e5890c94-11c6-65746ce6c560", "uuid": "e5890c94-11c6-4856-a7a6-65746ce6c560", "ownerId": "Dale9887" } Player ID 28
  • 29. Monster Document { "jsonType": "monster", Monster ID "name": "Bauchan9932", "uuid": "d10dfc1b-0412-4140-b4ec-affdbf2aa5ec", "hitpoints": 370, "experienceWhenKilled": 52, "itemProbability": 0.5050581341872865 } 29
  • 30. GAME ON! 30
  • 31. Full Text Search Integration • Elastic Search is good for ad-hoc queries and faceted browsing • Couchbase adapter uses XDCR to push mutations to ESDocs are indexed by Elastic Search • Couchbase ES Adapter is cluster-aware ElasticSearch Unidirectional Cross Data Center Replication 31
  • 32. Full Text Search Application Server Couchbase SDK ES Queries over HTTP Do ta TS c Da ery Qu Re Qu er fs M R y Couchbase Server Cluster ElasticSearch Server Cluster MR MR MR MR Views Views Views Views XDCR-based Cross Data Center Replication CB-ES Transport 32
  • 33. Couchbase SDKs Java SDK User Code .Net SDK Java client API CouchbaseClient cb = new CouchbaseClient(listURIs, "aBucket", "letmein"); cb.set("hello", 0, "world"); cb.get("hello"); Couchbase Java Library PHP SDK (spymemcached) Ruby SDK Couchbase Server …and many more http://www.couchbase.com/develop 33
  • 34. QUESTIONS? 34 3

Notes de l'éditeur

  1. Hello everyone, I am diptiborkar, director of product management at couchbase. I manage the product roadmap of couchbase server, our flagship product. And I’m really excited to talk to you about couchbase server 2.0
  2. Rapid app devwithouth the need to perform an expensive alter table operation.
  3. JSON support – natively stored as json, whne you build an app, there is not conversion required. New doc viewing , editing capability. Indexing and querying – look inside your json, build views and query for a key, for ranges or to aggregate data Incremental mapreduce – powers indexing. Build complex views over your data. Great for real-time analytics XDCR – replicate information from one cluster to another cluster
  4. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  5. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  6. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  7. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  8. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  9. Bulletize the text. Make sure the builds work.
  10. Bulletize the text. Make sure build work properly.
  11. Bulletize the text. Make sure build work properly.
  12. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  13. Bulletize the text. Make sure the builds work.
  14. Overview of what this feature is
  15. 1.  A set request comes in from the application .2.  Couchbase Server responses back that they key is written3. Couchbase Server then Replicates the data out to memory in the other nodes4. At the same time it is put the data into a write que to be persisted to disk
  16. Break out to demo here
  17. ElasticSearch cluster is fed the documents from the Couchbase Server clusterElastic search indexes the fields(configurable which ones) and by default will only store references back to the document idThe application does document access via the Couchbase Server Cluster and uses The Views and incremental map reduce on the Couchbase cluster.For full text queries it queries the Ealstic search cluster directly (simple Http and JSON interface)The full text queries typically returns the ids of the matching documents.Documents are then retrieved from the Couchbase Server cluster.This way the high throughput document access always comes from high performance Couchbase Cluster.