Couchbase Chennai meetup #3 What's new in Couchbase Server & Couchbase Mobile
Matt Ingenthron Couchbase, Inc.
Transcript of Matt Ingenthron Couchbase, Inc.
![Page 1: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/1.jpg)
Matt Ingenthron
Couchbase, Inc.
![Page 2: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/2.jpg)
2
![Page 3: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/3.jpg)
What is Membase?
![Page 4: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/4.jpg)
Before: Application scales linearly, data hits wall
Application Scales OutJust add more commodity web servers
Database Scales UpGet a bigger, more complex server
4
![Page 5: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/5.jpg)
Membase is a distributed database
5
Membase Servers
In the data center
Web application server
Application user
On the administrator console
Web application serverWeb application server
![Page 6: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/6.jpg)
Five minutes or less to a working cluster• Downloads for Linux and Windows• Start with a single node• One button press joins nodes to a clusterEasy to develop against• Just SET and GET – no schema required• Drop it in. 10,000+ existing applications
already “speak membase” (via memcached)• Practically every language and application
framework is supported, out of the boxEasy to manage• One-click failover and cluster rebalancing• Graphical and programmatic interfaces• Configurable alerting
Membase is Simple, Fast, Elastic
6
![Page 7: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/7.jpg)
Membase is Simple, Fast, Elastic
7
Predictable• “Never keep an application waiting”• Quasi-deterministic latency and throughputLow latency• Built-in Memcached technology
High throughput• Multi-threaded• Low lock contention• Asynchronous wherever possible• Automatic write de-duplication
![Page 8: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/8.jpg)
Membase is Simple, Fast, Elastic
8
Zero-downtime elasticity• Spread I/O and data across commodity
servers (or VMs) • Consistent performance with linear cost• Dynamic rebalancing of a live clusterAll nodes are created equal• No special case nodes• Any node can replace any other node, online• Clone to growExtensible• Filtered TAP interface provides hook points
for external systems (e.g. full-text search, backup, warehouse)
• Data bucket – engine API for specialized container types
![Page 9: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/9.jpg)
Built-in Memcached Caching Layer
9
Memcached
Membase Database
Membase Cache
Membase Database
Memcached Mode Membase Mode
Fact: Membase development team has also contributed over half of the code to the Memcached project.
![Page 10: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/10.jpg)
Use Cases
![Page 11: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/11.jpg)
Ad targeting
11
eventsprofiles, campaigns
profiles, real time campaign statistics
40 milliseconds to come up with an answer.
2
3
1
![Page 12: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/12.jpg)
Search and Gaming Portal
12
Database
![Page 13: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/13.jpg)
Membase Architecture
![Page 14: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/14.jpg)
Clustering
• Underlying cluster functionality based on erlang OTP
• Have a custom, vector clock based way of storing and propagating...– Cluster topology– vBucket mapping
• Collect statistics from many nodes of the cluster– Identify hot keys, resource
utilization
14
![Page 15: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/15.jpg)
A Membase Node
15
Membase Node
REST Interfacememcached operations(any client)
memcached smart client operations
![Page 16: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/16.jpg)
16
ns_servermembase(memcached + membase engine)
moxi ns_server
vbucketmigrator
TAP
A Membase Node: Component View
![Page 17: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/17.jpg)
ns_servermembase(memcached + membase engine)
moxi ns_server
vbucketmigratorTAP
memcached operationswith tap commands
memcached operations
Client
port 11211 memcached operations
moxi + Client
port 11210 memcached operations REST/comet
cluster topology and vbucket map
Clients, nodes and other nodes
17
![Page 18: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/18.jpg)
Data buckets are secure Membase “slices”
18
Membase data servers
In the data center
Web application server
Application user
On the administrator console
Bucket 1Bucket 2
Aggregate Cluster Memory and Disk Capacity
![Page 19: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/19.jpg)
Disk > Memory
Buc
ket C
onfig
urat
ion
mem_high_wat
mem_low_wat
memory quota
19
Dataset may have many items infrequently accessed. However, memcached has different behavior (LRU) than wanted with membase.
Still, traditional (most) RDBMS implementations are not 100% correct for us either. The speed of a miss is very, very important.
![Page 20: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/20.jpg)
Membase Demo
![Page 21: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/21.jpg)
The Future
![Page 22: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/22.jpg)
But first, an intro...
22
![Page 23: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/23.jpg)
What is Couchbase?
23
1+1 really does equal 3
![Page 24: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/24.jpg)
Where will the merger take us
24
mobile elastic
• Sub-document manipulation• New approaches to indexing• Simplified development
![Page 25: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/25.jpg)
Attributions
• http://commons.wikimedia.org/wiki/File:Flag_of_China.png
• http://commons.wikimedia.org/wiki/File:Flag_of_South_Korea.svg
• http://commons.wikimedia.org/wiki/File:Flag_of_Japan.svg
25
![Page 26: Matt Ingenthron Couchbase, Inc.](https://reader033.fdocuments.in/reader033/viewer/2022051114/62773f8a0920932ff32e837f/html5/thumbnails/26.jpg)
26