Couchbase Server 2.0 Use Cases
description
Transcript of Couchbase Server 2.0 Use Cases
1
Couchbase Server Common use cases
Dipti BorkarDirector, Product Management
2
Couchbase Server 2.0 - Webinar Series
Couchbase Server 2.0 and Indexing/Querying
Couchbase Server 2.0 and Incremental Map Reduce for Real-Time Analytics
Couchbase Server 2.0 and Cross Data Center Replication
Couchbase Server 2.0 and Full-Text Search Integration
Couchbase Server 2.0 Use Cases Overview
Introducing Couchbase Server 2.0
http://www.couchbase.com/webinars
3
2 major types of data management systems
OLTP / ODS
Analytics / EDW
4
OLTP / ODS
Analytics / EDW
2 major types of data management systems
5
OLTP / ODS
Analytics / EDW
2 major types of data management systems
6
2 major types of data management systems
NoSQL
7
Map-reduce / batch processing against huge datasets for pattern matching, insights and answers
Simple, fast, elastic NoSQL database with sub-millisecond performance at scale
2 major types of data management systems
8
NoSQL Database Considerations
Easy Scalability
Consistent High Performance
FlexibleData Model
Always On 24x7x365
Grow cluster without application changes, without downtime
when needed
Always awesome experience for your application users.
The sun never sets on the Internet, your application needs the database
to always serve data.
Keep developers productive and allow fast and easy addition of
new features
9
2.0
NoSQL Document Database for interactive
applications
Couchbase Server
10
Easy Scalabili
ty
Consistent, High
Performance
Always On
24x7x365
Grow cluster without application changes, without downtime with a single click
Consistent sub-millisecond read and write response times with consistent high throughput
No downtime for software upgrades, hardware maintenance, etc.
Couchbase Server
11
Flexible Data Model
• 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
{ “ID”: 1, “FIRST”: “Dipti”, “LAST”: “Borkar”, “ZIP”: “94040”, “CITY”: “MV”, “STATE”: “CA”}
JSONJSON
JSON JSON
12
New in Two
JSON support Indexing and Querying
Cross data center replicationIncremental Map Reduce
13
Market Adoption
Internet Companies Enterprises
• Social Gaming• Ad Networks• Social Networks• Online Business
Services• E-Commerce• Online Media• Content Management• Cloud Services
• Communications
• Retail
• Financial Services
• Health Care
• Automotive/Airline
• Agriculture
• Consumer Electronics
• Business Systems
14
Market Adoption – Customers
Internet Companies Enterprises
More than 300 customers -- 5,000 production deployments worldwide
15
USE CASE AND APPLICATIONEXAMPLES
16
Application Characteristics - Data driven
• 3rd party or user defined structure (Twitter feeds)• Support for unlimited data growth (Viral apps)• Data with non-homogenous structure • Need to quickly and often change data structure• Variable length documents• Sparse data records• Hierarchical data
Couchbase is a good fit
17
Application Characteristics - Performance driven
• Low latency critical (ex. 1millisecond)• High throughput (ex. 200000 ops / sec)• Large number of users • Unknown demand with sudden growth of
users/data • Predominantly direct document access• Read / Mixed / Write heavy workloads
Couchbase is a good fit
18
Use Case Examples
Web app or Use-case Couchbase Solution Example Customer
Content and Metadata Management System
Couchbase document store + Elastic Search McGraw-Hill…
Social Game or Mobile App
Couchbase stores game and player data Zynga…
Ad Targeting Couchbase stores user information for fast access
AOL…
User Profile Store Couchbase Server as a key-value store TuneWiki…
Session Store Couchbase Server as a key-value store Concur….
High Availability Caching Tier
Couchbase Server as a memcached tier replacement
Orbitz…
Chat/Messaging Platform
Couchbase Server DOCOMO…
19
• User account information• User game profile info• User’s social graph• State of the game• Player badges and stats
Social and Mobile Gaming
• Ability to support rapid growth• Fast response times for
awesome user experience• Game uptime –24x7x365• Easy to update apps with new
features
• Scalability ensures that games are ready to handle the millions of users that come with viral growth.
• High performance guarantees players are never left waiting to make their next move.
• Always-on operations means zero interruption to game play (and revenue)
• Flexible data model means games can be developed rapidly and updated easily with new features
Types of Data Application Requirements
Why NoSQL and Couchbase
Use Case: Social Gaming
20
Example: Data Profile for Players
{ “UUID”: “21f7f8de-8051-5b89-86“Time”: “2011-04-01T13:01:02.42“Server”: “A2223E”,“Calling Server”: “A2213W”,“Type”: “E100”,“Initiating User”: “[email protected]”,“Details”:
{“IP”: “10.1.1.22”,“API”: “InsertDVDQueueItem”,“Trace”: “cleansed”,“Tags”:
[“SERVER”, “US-West”, “API”]
}}
{ “_id”: “auser_profile”, “user_id”: 7778 “password”: “a1004cdcaa3191b7”, ”common_name”: ”Robert User”, ”nicknames”: [”Bob”, ”Buddy”], "sign_up_timestamp": 1224612317, "last_login_timestamp": 1245613101}
{ “UUID”: “21f7f8de-8051-5b89-86“Time”: “2011-04-01T13:01:02.42“Server”: “A2223E”,“Calling Server”: “A2213W”,“Type”: “E100”,“Initiating User”: “[email protected]”,“Details”:
{“IP”: “10.1.1.22”,“API”: “InsertDVDQueueItem”,“Trace”: “cleansed”,“Tags”:
[“SERVER”, “US-West”, “API”]
}}
{ “_id”: “auser_friends”, “friends”: [ “joe”, “alan”, “toru” ]}
21
• User profile: preferences and psychographic data
• Ad serving history by user• Ad buying history by
advertiser • Ad serving history by
advertiser
Ad Targeting
• High performance to meet limited ad serving budget; time allowance is typically <40 msec
• Scalability to handle hundreds of millions of user profiles and rapidly growing amount of data
• 24x7x365 availability to avoid ad revenue loss
• Sub-millisecond reads/writes means less time is needed for data access, more time is available for ad logic processing, and more highly optimized ads will be served
• Ease of scalability ensures that the data cluster can be grown seamlessly as the amount of user and ad data grows
• Always-on operations = always-on revenue. You will never miss the opportunity to serve an ad because downtime.
Types of Data Application Requirements
Why NoSQL and Couchbase
Use Case: Ad Targeting
22
Ad and offer targeting: Data flow
raw event datacooked insights
profiles, campaigns / offers,cooked insights
40 milliseconds to pick the right offer
raw
eve
nt d
ata
actio
nabl
e in
sigh
ts
Ad Targeting
23
Ad Targeting: Content Recommendation
events
user profiles
targetedrecommendations
2
3
1
contentoriented site
relationaldatabase
24
Ad Targeting
25
Use Case: Content and metadata store
Building a self-adapting, interactive learning portal with Couchbase
26
As learning move online in great numbers
Growing need to build interactive learning environments that
Scale!
Scale to millions of learners
Serve MHE as well as third-party content
Including open content
Support learning apps
010100100111010101010101001010101010
Self-adapt via usage data
The Problem
27
• Allow for elastic scaling under spike periods
• Ability to catalog & deliver content from many sources
• Consistent low-latency for metadata and stats access
• Require full-text search support for content discovery
• Offer tunable content ranking & recommendation functions
Backend is an Interactive Content Delivery Cloud that must:
XML Databases
SQL/MR Engines
In-memory Data Grids
Enterprise Search Servers
Experimented with a combination of:
Hmmm...this looks kinda like:+ Content Caching (Scale)+ Social Gaming (Stats) + Ad Targeting (Smarts)
The Challenge
28
The Technologies
29
The Learning Portal
• Designed and built as a collaboration between MHE Labs and Couchbase
• Serves as proof-of-concept and testing harness for Couchbase + ElasticSearch integration
• Available for download and further development as open source code
https://github.com/couchbaselabs/learningportal
30
Architecture
31
Sample JSON document
32
View from the app
Content tagging
Content contribution
Content stats
33
Couchbase Server Features used: Views
34
View definition example
35
Couchbase Server Features used : Full-text integration
36
2.0 Betais Here.
JSON Documents Indexing Querying
Cross Data Center Replication
http://www.couchbase.com/couchbase-server/beta