mongodb atlas - on tour!: introduction to mongodb

31
Intro to MongoDB

Upload: mongodb

Post on 16-Apr-2017

325 views

Category:

Technology


11 download

TRANSCRIPT

Page 1: MongoDB Atlas - On Tour!: Introduction to MongoDB

Intro to MongoDB

Page 2: MongoDB Atlas - On Tour!: Introduction to MongoDB

Fastest-Growing Database

Facebook

LinkedInGoogle

Twitter

Page 3: MongoDB Atlas - On Tour!: Introduction to MongoDB

4th Most PopularRANK DBMS MODEL SCORE GROWTH (20 MO)

1. Oracle Relational DBMS 1,442 -5%

2. MySQL Relational DBMS 1,294 2%

3. Microsoft SQL Server Relational DBMS 1,131 -10%

4. MongoDB Document Store 277 172%

5. PostgreSQL Relational DBMS 273 40%

6. DB2 Relational DBMS 201 11%

7. Microsoft Access Relational DBMS 146 -26%

8. Cassandra Wide Column 107 87%

9. SQLite Relational DBMS 105 19%

Source: DB-engines database popularity rankings; May 2015

Page 4: MongoDB Atlas - On Tour!: Introduction to MongoDB

20,000,000+MongoDB Downloads

400,000+Online Education Students

40,000+MongoDB Cloud Manager Users

35,000+MongoDB User Group Members

1,000+Technology and Services Partners

2,000+Customers Across All Industries

The Largest Ecosystem

Page 5: MongoDB Atlas - On Tour!: Introduction to MongoDB

Optimizing for Engineering Productivity1985 2016

Engineer Costs

Infrastructure Costs

Page 6: MongoDB Atlas - On Tour!: Introduction to MongoDB
Page 7: MongoDB Atlas - On Tour!: Introduction to MongoDB

Relational Data ModelGameGameIDPlayerOneIDPlayerTwoIDGameParam1GameParamNStartTimeEndTimeState

GameMovesGameIDMoveIDPlayerIDMoveTokenTimestamp

PlayerPlayerIDNameWinsLossesEmailPassword

Dashboard1

GameIDDashIDPlacement<De-normalized Fields?>

Page 8: MongoDB Atlas - On Tour!: Introduction to MongoDB

JSON Style

game {player_one: PlayerID,player_two: PlayerID,moves [ { token: <moveToken1>, ts: timestamp1 }, { token:

<moveToken2>, ts: timestamp2 ... ],game_parameters: { param1 : v, param2 : v, ... },start_time: ts,end_time: ts,state: <state>, // in_play, mate, resign, draw

winner: W || B || D}

Page 9: MongoDB Atlas - On Tour!: Introduction to MongoDB

Documents are Rich Data Structures{ first_name: ‘Paul’, surname: ‘Miller’, cell: 447557505611, city: ‘London’, location: [45.123,47.232], Profession: [‘banking’, ‘finance’, ‘trader’], cars: [ { model: ‘Bentley’, year: 1973, value: 100000, … }, { model: ‘Rolls Royce’, year: 1965, value: 330000, … } ]}

Fields can contain an array of sub-documents

Typed field values

Fields can contain arrays

String

Number

Geo-Location

Fields

Page 10: MongoDB Atlas - On Tour!: Introduction to MongoDB

Documents are Flexible

{ product_name: ‘Acme Paint’, color: [‘Red’, ‘Green’], size_oz: [8, 32], finish: [‘satin’, ‘eggshell’]

}

{ product_name: ‘T-shirt’, size: [‘S’, ‘M’, ‘L’, ‘XL’], color: [‘Heather Gray’ … ], material: ‘100% cotton’, wash: ‘cold’, dry: ‘tumble dry low’}

{ product_name: ‘Mountain Bike’, brake_style: ‘mechanical disc’, color: ‘grey’, frame_material: ‘aluminum’, no_speeds: 21, package_height: ‘7.5x32.9x55’, weight_lbs: 44.05, suspension_type: ‘dual’, wheel_size_in: 26}

Documents in the same product catalog collection in MongoDB

Page 11: MongoDB Atlas - On Tour!: Introduction to MongoDB

Drivers & Frameworks

Morphia

MEAN Stack

Page 12: MongoDB Atlas - On Tour!: Introduction to MongoDB

Development – The Past

{ CODE } DB SCHEMAXML CONFIG

APPLICATION RELATIONAL DATABASEOBJECT RELATIONAL MAPPING

Page 13: MongoDB Atlas - On Tour!: Introduction to MongoDB

Development – With MongoDB

{ CODE } DB SCHEMAXML CONFIG

APPLICATION RELATIONAL DATABASEOBJECT RELATIONAL MAPPING

Page 14: MongoDB Atlas - On Tour!: Introduction to MongoDB

Expressive Query Language

Rich Queries Find Paul’s carsFind everybody in London with a car between 1970 and 1980

Geospatial Find all of the car owners within 5km of Trafalgar Sq.

Text Search Find all the cars described as having leather seats

Aggregation Calculate the average value of Paul’s car collection

Map Reduce What is the ownership pattern of colors by geography over time (is purple trending in China?)

Page 15: MongoDB Atlas - On Tour!: Introduction to MongoDB

Highly Availability & Scalability

Page 16: MongoDB Atlas - On Tour!: Introduction to MongoDB

High Availability & Elastic ScalabilityApplication

Driver

Primary

Secondary

SecondaryRep

licat

ion

Acr

oss

Ava

ilabi

lity

Zone

s

Query Router

Primary

Secondary

Secondary

Primary

Secondary

Secondary

Shard 1 Shard 2 Shard 3

… Shard N

Page 17: MongoDB Atlas - On Tour!: Introduction to MongoDB

Replicate Data Near Users

Page 18: MongoDB Atlas - On Tour!: Introduction to MongoDB

Deploy Global, Access Local

Page 19: MongoDB Atlas - On Tour!: Introduction to MongoDB

MongoDB AtlasThe Easiest Way to Get Started

Page 20: MongoDB Atlas - On Tour!: Introduction to MongoDB

Operations Burden

PATCHES

UPGRADES

SECURITY

BACKUPS

RECOVERY

99.999% UPTIME

UPSCALE

DOWNSCALE

PERFORMANCE

UAT

STAGING

MONITORING

ALERTS

PROVISION

CONFIGURE

INSTALL

Page 21: MongoDB Atlas - On Tour!: Introduction to MongoDB

Automated Available On-Demand

Secure Highly Available Automated Backups

Elastically Scalable

Database as a Service for MongoDB

Page 22: MongoDB Atlas - On Tour!: Introduction to MongoDB

Cloud Hosted MongoDB Under the hood

● MongoDB Atlas is currently* available as a hosted solution in

four AWS regions

● All regions have a minimum of three Availability Zones

Current Regions:

● eu-west-1 (Dublin)

● us-east-1 (N. Virginia)

● us-west-1 (N. California)

● ap-southeast-2 (Sydney)

*additional regions coming soon

Page 23: MongoDB Atlas - On Tour!: Introduction to MongoDB

High PerformanceUnder the hood

● WiredTiger storage engine with compression and fine-grained

concurrency control

● MongoDB Atlas supports automatic-sharding, giving you the ability

to scale up or out with no impact to your app

● MongoDB Atlas allows you to pick the shard key that best suits your

application needs

● All MongoDB Atlas clusters are single-tenant and deployed on

servers allocated specifically to the cluster

● Workload isolation with up to seven replicas of your data to

concurrently run operational and analytical workloads across the

same database, without any resource contention

Page 24: MongoDB Atlas - On Tour!: Introduction to MongoDB

Secure in the CloudUnder the hood

All MongoDB Atlas nodes are single-tenant and deployed into their own

VPC for security isolation.

In-flight security:

● TLS/SSL for in-flight data encryption

● Authentication and authorization access controls with SCRAM-SHA1

● IP whitelists enforced with AWS Security Groups*

At-rest security:

● AWS encrypted storage volumes

● AES-256 (CBC mode) hardware encryption with Seagate Self-

Encrypting Drives

*VPC Peering coming soon

Page 25: MongoDB Atlas - On Tour!: Introduction to MongoDB

Highly Available by DefaultUnder the hood

● A minimum of three data nodes per replica

set/shard are automatically deployed across

availability zones for high availability

● If your primary node does go down for any

reason, the self healing recovery process in

MongoDB Atlas will typically occur in under 2

seconds

Page 26: MongoDB Atlas - On Tour!: Introduction to MongoDB

Continuous Backup / Point-in-time Restore Under the hood

● MongoDB Atlas continuously backs up your data, ensuring your

backups are typically just a few seconds behind the operational

system

● Point-in-time backup of replica sets and consistent, cluster-wide

snapshots of sharded clusters. With MongoDB Atlas, you can easily

and safely restore to precisely the moment you need

● Compression and block-level deduplication technology keeps your

backup processes as efficient as possible

● Backups are securely stored in North America*. For location flexibility

of your backup data, you can utilize MongoDB’s mongodump /

mongorestore tools

*Non-US storage regions for backup coming soon

Page 27: MongoDB Atlas - On Tour!: Introduction to MongoDB

Square Enix built their MongoDB as a service on Amazon Web Services

• MongoDB deployed in AWS is delivered as a service across all studios and developers

• MongoDB stores metrics, player profiles, leaderboards, and competitions. It also

support X platform messaging and serves as the backend for web and mobile sites.

Finally, the database’s flexibility makes it easier to develop game-specific functionality

Results

• 3 week query in relational database 2 minutes with MongoDB

• Zero downtime in 5 years

• Each game generates on average 120 GB of data per day; easy to manage and

scale with MongoDB on AWS

“The latest Tomb Raider game, is able to generate

roughly around half a terabyte of data per day.

MongoDB helps us to manage all this and run all

these operations [with] quite a small team.”

Tomas Jelinek, Senior Online Operations Administrator, Square Enix

“MongoDB Atlas hits the sweet spot between do-it-yourself and hands off when it comes to managed database infrastructure.”

- Aaron King, VP of Product Engineering at Social News Desk

“MongoDB Atlas has allowed us to elevate our product to the next level. This put us in a position to rapidly scale with our exploding customer base.”

- Justin McCormack, co-founder and CTO at Fleetpin

“We’ve already started migrating from our previous vendor to MongoDB Atlas and have been getting fantastic performance. The interface is so simple, and the process of creating a cluster was a breeze!”

- Bent Foyn, Development Manager at Visma Software International

Page 28: MongoDB Atlas - On Tour!: Introduction to MongoDB

Operations Burden

PATCHES

UPGRADES

SECURITY

BACKUPS

RECOVERY

99.999% UPTIME

UPSCALE

DOWNSCALE

PERFORMANCE

UAT

STAGING

MONITORING

ALERTS

PROVISION

CONFIGURE

INSTALL

Page 29: MongoDB Atlas - On Tour!: Introduction to MongoDB

DEMO

Page 30: MongoDB Atlas - On Tour!: Introduction to MongoDB

Now try it yourself!

Use the code goAtlas25 for a $25 discountwww.mongodb.com/atlas

For a limited time only

Page 31: MongoDB Atlas - On Tour!: Introduction to MongoDB

Join us at MongoDB World 2017June 20-21Chicago, ILBringing together 3000 developers, architects, IT professionals and executive decision makers, MongoDB World is the foremost conference dedicated to the database for giant ideas.

www.mongodb.com/events/mongodb-world-2017