CouchbaseServer 2.0
Couchbase Server 2.0                =                    Simple. Fast. Elastic.
Couch API                                                                                                                M...
Couchbase Server 2.0 Architecture  5984           11211             11210  Couch View     Memcapable 1.0    Memcapable 2.0...
Couchbase Client SDKsJava ClientSDK              User Code.Net SDK       Java client API                                  ...
Partitioning The Data – vbucket map
Couchbase Server Basic Operation                   APP SERVER 1                                     APP SERVER 2          ...
Add Nodes                  APP SERVER 1                                APP SERVER 2                                       ...
Fail Over Node                                                                                                           ...
DEMO TIME
Demo: The next big social game3 Objects (documents) within game:    • Players    • Monsters    • ItemsGameplay:   • Player...
Player Document{    "_id": "Keith4540",    "_rev": "1-ab354009ce09f198c555b693e057adce",    "jsonType": "player",    "uuid...
Item Document{    "_id": "Katana_e5890c94-11c6-48-65746ce6c560",    "_rev": "1-d6bbd5e814c32c66e22db2918a2efcd9",    "json...
Monster Document{    "_id": "Bauchan9932",    "_rev": "1-5c90be58be58134a0fc5e7db77dab5f2",    "jsonType": "monster",    "...
GAME ON!
Performance Optimizations                     • Much improved bulk                       loading performance              ...
JSON Documents
Indexing and Querying                  APP SERVER 1                                APP SERVER 2                   APP SERV...
Cross Data Center ReplicationUS DATA CENTER                       EUROPE DATA CENTER                           ASIA DATA C...
DEMO TIME
THANK YOU!      Get Couchbase Server 2.0 athttp://www.couchbase.com/downloads         Give us feedback at:  http://www.cou...
Upcoming SlideShare
Loading in...5
×

CouchConf-Chicago-Couchbase-2.0

504

Published on

Published in: Technology, News & Politics
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
504
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
5
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • CAPI interface – basic Couch API of which some goes through the caching layer (CRUD), some goes directly to Couch (Views)
  • CouchConf-Chicago-Couchbase-2.0

    1. 1. CouchbaseServer 2.0
    2. 2. Couchbase Server 2.0 = Simple. Fast. Elastic.
    3. 3. Couch API Moxi Database Operations Data Manager Membase EP Engine storage interface REST management API/Web UI http Heartbeat Process monitor Configuration manager on each node Global singleton supervisor Erlang/OTP Couchbase Server 2.0 Architecture Rebalance orchestratorCluster Management Node health monitor vBucket state and replication manager Cluster Manager one per cluster
    4. 4. Couchbase Server 2.0 Architecture 5984 11211 11210 Couch View Memcapable 1.0 Memcapable 2.0 Moxi REST management API/Web UI vBucket state and replication manager Couch API Memcached Global singleton supervisor Rebalance orchestrator Configuration manager Node health monitor Process monitor Heartbeat Membase EP Engine Membase storage interface CouchDB http on each node one per cluster Erlang/OTP HTTP Erlang port mapper Distributed Erlang 8091 4369 21100 - 21199
    5. 5. Couchbase Client SDKsJava ClientSDK User Code.Net SDK Java client API CouchbaseClient cb = new CouchbaseClient(listURIs, "aBucket", "letmein"); // this is all the same as before cb.set("hello", 0, "world"); cb.get("hello"); spymemcached HTTP couchDB Map<String, Object> manyThings =PHP SDK Connection connection cb.getBulk(Collection<String> keys); /* accessing a view View view = cb.getView("design_document", "my_view"); Query query = new Query(); query.getRange("abegin", "theend");Ruby SDK Couchbase ServerPython SDK http://www.couchbase.org/code
    6. 6. Partitioning The Data – vbucket map
    7. 7. Couchbase Server Basic Operation APP SERVER 1 APP SERVER 2  Docs distributed evenly across COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY servers in the cluster  Each server stores both active CLUSTER MAP CLUSTER MAP & replica docs  Only one server active at a time  Client library provides app with Read/Write/Update Read/Write/Update simple interface to database  Cluster map provides map to which server doc is on  App never needs to know SERVER 1 SERVER 2 SERVER 3  App reads, writes, updates Active Docs Active Docs Active Docs docs Doc 5 DOC Doc 4 DOC Doc 1 DOC  Multiple App Servers can Doc 2 DOC Doc 7 DOC Doc 3 DOC access same document at Doc 9 DOC Doc 8 DOC Doc 6 DOC same time Replica Docs Replica Docs Replica Docs Doc 4 DOC Doc 6 DOC Doc 7 DOC Doc 1 DOC Doc 3 DOC Doc 9 DOC Doc 8 DOC Doc 2 DOC Doc 5 DOC COUCHBASE SERVER CLUSTERUser Configured Replica Count = 1
    8. 8. Add Nodes APP SERVER 1 APP SERVER 2  Two servers added to COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY cluster  One-click operation CLUSTER MAP CLUSTER MAP  Docs automatically rebalanced across cluster  Even distribution of docs Read/Write/Update Read/Write/Update  Minimum doc movement  Cluster map updated  App database calls now distributed over larger # SERVER 1 SERVER 2 SERVER 3 SERVER 4 SERVER 5 of servers Active Docs Active Docs Active Docs Active Docs Active Docs Active Docs Doc 5 DOC Doc 4 DOC Doc 1 DOC Doc 3 Doc 2 DOC Doc 7 DOC Doc 3 DOC Doc 6 Doc 9 DOC Doc 8 DOC Doc 6 DOC Replica Docs Replica Docs Replica Docs Replica Docs Replica Docs Replica Docs Doc 4 DOC Doc 6 DOC Doc 7 DOC Doc 7 Doc 1 DOC Doc 3 DOC Doc 9 DOC Doc 9 Doc 8 DOC Doc 2 DOC Doc 5 DOC COUCHBASE SERVER CLUSTERUser Configured Replica Count = 1
    9. 9. Fail Over Node  App servers happily accessing docs on Server 3 COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY  Server fails  App server requests to server 3 fail CLUSTER MAP CLUSTER MAP  Cluster detects server has failed  Promotes replicas of docs to active  Updates cluster map  App server requests for docs now go to appropriate server  Typically rebalance would follow SERVER 1 SERVER 2 SERVER 3 SERVER 4 SERVER 5 Active Docs Active Docs Active Docs Active Docs Active Docs Active Docs Doc 5 DOC Doc 4 DOC Doc 1 DOC Doc 9 DOC Doc 6 DOC Doc 3 Doc 2 DOC Doc 7 DOC Doc 3 Doc 8 DOC Doc 6 DOC Replica Docs Replica Docs Replica Docs Replica Docs Replica Docs Replica Docs Doc 4 DOC Doc 6 DOC Doc 7 DOC Doc 5 DOC Doc 8 DOC Doc 7 Doc 1 DOC Doc 3 DOC Doc 9 DOC Doc 2 DOC Doc 9 COUCHBASE SERVER CLUSTERUser Configured Replica Count = 1
    10. 10. DEMO TIME
    11. 11. Demo: The next big social game3 Objects (documents) within game: • Players • Monsters • ItemsGameplay: • Players fight monsters • Monsters drop items • Players own items
    12. 12. Player Document{ "_id": "Keith4540", "_rev": "1-ab354009ce09f198c555b693e057adce", "jsonType": "player", "uuid": "35767d02-a958-4b83-8179-616816692de1", "name": "Keith4540", "hitpoints": 75, "experience": 663, "level": 4, "loggedIn": false}
    13. 13. Item Document{ "_id": "Katana_e5890c94-11c6-48-65746ce6c560", "_rev": "1-d6bbd5e814c32c66e22db2918a2efcd9", "jsonType": "item", "name": "Katana_e5890c94-11c6-65746ce6c560", "uuid": "e5890c94-11c6-4856-a7a6-65746ce6c560", "ownerId": "Dale9887"} Player “_id”
    14. 14. Monster Document{ "_id": "Bauchan9932", "_rev": "1-5c90be58be58134a0fc5e7db77dab5f2", "jsonType": "monster", "name": "Bauchan9932", "uuid": "d10dfc1b-0412-4140-b4ec-affdbf2aa5ec", "hitpoints": 370, "experienceWhenKilled": 52, "itemProbability": 0.5050581341872865}
    15. 15. GAME ON!
    16. 16. Performance Optimizations • Much improved bulk loading performance • Significantly better indexing performance • Disk Storage Reduction
    17. 17. JSON Documents
    18. 18. Indexing and Querying APP SERVER 1 APP SERVER 2 APP SERVER 1 APP SERVER 2  Indexing work is distributed COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY COUCHBASE CLIENT LIBRARY amongst nodes  Large data set possible CLUSTER MAP MAP CLUSTER CLUSTER MAPMAP CLUSTER  Parallelize the effort  Each node has index for data stored on it Query Response  Queries combine the results from required nodes SERVER 1 SERVER 2 SERVER 3 Active Docs Active Docs Active Docs Doc 5 DOC Doc 4 DOC Doc 1 DOC Doc 2 DOC Doc 7 DOC Doc 3 DOC Doc 9 DOC Doc 8 DOC Doc 6 DOC Replica Docs Replica Docs Replica Docs Doc 4 DOC Doc 6 DOC Doc 7 DOC Doc 1 DOC Doc 3 DOC Doc 9 DOC Doc 8 DOC Doc 2 DOC Doc 5 DOCUser Configured Replica Count = 1
    19. 19. Cross Data Center ReplicationUS DATA CENTER EUROPE DATA CENTER ASIA DATA CENTER CouchSync CouchSync CouchSync  Want data close to user  Want multiple locations for disaster recovery  Can write to same document in all different regions & it will sync
    20. 20. DEMO TIME
    21. 21. THANK YOU! Get Couchbase Server 2.0 athttp://www.couchbase.com/downloads Give us feedback at: http://www.couchbase.org/forums
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×