Gluecon 2012 - DynamoDB

Jeff Douglas
Jeff DouglasSenior Technical Consultant at Appirio
¡Ay, caramba!

  Wrestle Your NoSQL
  Data with DynamoDB
 Je ff Dougl a s @je ff do n th em ic
 C lo udSp ok es C ommun it y Arch itec t
Rambling Talk Roadmap

Short NoSQL overview (thanks Max @ 10gen!)

Why NoSQL database are like Mexican Wrestlers

Amazon DynamoDB in depth

Amazon DynamoDB demo and code

CloudSpokes challenge submissions for “Build an
#Awesome Demo with Amazon DynamoDB”
Times they are a-changin’

    Cloud applications and
    APIs need to be fast,
    flexible and scalable.

    RDBMS typically do not
    scale well for certain data-intensive application.

    NoSQL is cloud friendly.
“NoSQL is a rebellion against the DBAs who prevent us from
                        doing shit.”
                          - James Governor, Gluecon 2012
Why is NoSQL #awesome?
Developed to manage large volumes of data that
do not necessarily follow a fixed schema

Great for heavy read/write workloads

Simple to setup, configure and administer

Distributed, fault tolerant architecture

Scale out not up

Specialized database for the right task
Key NoSQL differences

Do not use SQL as a query language

Dynamic & schema-less

Non-relational, no JOIN operations

No complex transactions

May not give full ACID guarantees; eventually
consistent instead. Performance and real-time
nature is more important than consistency.
NoSQL databases are
    “different”
NoSQL database types

Document store (MongoDB, CouchDB)
 A document-oriented database that stores, retrieves, and manages semi
 structured data including XML, YAML, JSON and binary (PDF, DOC)


Key-value store (Cassandra, Redis)
 Stores scheme-less data referenced by a simple key value


Graph database (Neo4j, FlockDB)
 Stores the relationship of data as a graph (social relations, network
 topologies)
How to choose?
With all of the different NoSQL database types, how
            do you choose the “best” one?
El Toro Más Macho
                    MongoDB
       Stores structured data as JSON-like
       documents.

       Ad hoc queries, indexing, master-slave
       replication, sharding, server-side JavaScript
       execution

       All the “cool kids” are using it.

       Node.js + MongoDB = WINNING!
Muy Guapo
              Couchbase
   JSON Document store

   Embedded CouchDB with caching,
   clustering and high-performance storage
   management components.

   JavaScript as its query language and
   HTTP for an API

   Serve HTML and JavaScript-based
   “CouchApps”
El Matador Misterio
                         Redis
        What exactly is redis? MAGIC!

        By definition, it’s an in-memory, key-value
        data store with optional durability.

        Data model includes list of string, sets of
        strings, sorted sets of strings & hashes.

        Awesome at doing set comparisons.
Comando Loco
              Apache Hadoop

    Fast, reliable analysis of both structured data
    and complex data.

    Derived from Google's MapReduce and File
    System (GFS) papers. Yahoo is one of the
    main contributors.

    Reliable data storage using the Hadoop
    Distributed File System (HDFS) and high-
    performance parallel data processing using
    MapReduce.
El Jefe Supremo
              Apache Cassandra
     Massively scalable key-value store initially
     developed by Facebook.

     BigTable data model (nested hashes) running
     on an Amazon Dynamo-like infrastructure.

     Has some RDBMS “feel” with column families
     that make it it a hybrid column/row store.

     No single point of failure, fault-tolerant multi
     data center replication, MapReduce support.

     CQL (Cassandra Query Language)
Introducing...
La Amazon DynamoDB
¡Hola DynamoDB

Amazon DynamoDB is a fast, fully managed key-value
database service that scales seamlessly with extremely
low latency and predictable performance.

   Store and retrieve any amount of data

   Serve any level of request traffic

   Hands off administration

   Pay for throughput and not storage
¡No! administración
No hardware or software provisioning, setup and
configuration, software patching, or partitioning data over
multiple instances and regions.

Specify the request throughput for your table and in the
background, Amazon handles the provisioning of resources to
meet the requested throughput rate.

Automatically partitions/re-partitions data and provisions
additional server capacity based upon table size & throughput.

Synchronously replicates data across multiple facilities in an
AWS Region giving you high availability and data durability.
Muy rápido

Consistent, predictable performance

Runs on a new solid state disk (SSD) architecture
for low-latency response times.

Read latencies average less than 5 milliseconds,
and write latencies average less than 10
milliseconds.
Muy Escalable

No table size limits (adiós SimpleDB?)

No downtime when scaling up or down

Unlimited storage

Automatically scale machine resources in
response to increases in database traffic without
the need of client-side partitioning.
Modelo de datos flexible

Flexible data model with familiar tables, items
and key-value pairs.

Schema-less document storage. Each item can
have different attributes.

Easy to create and modify documents. Simple
API.

No cross-table joins. Use composite keys to
model relationships.
Duradero

Consistent, disk-only writes

Atomic increment/decrement (w/single API call)

Optimistic concurrency control (aka conditional
writes & updates)

Item level transactions (even in bulk)

Automatic and synchronous replication across
data centers and availability zones.
Costos?

Pay for throughput and not storage.

Priced per hour of provisioned read/write
throughput

Scales up and down well with a free tier
Write throughput

Write throughput

Unit = size of item x writes/second

$0.01 per hour for 10 write units
Read throughput
Strongly consistent reads (mucho dinero)

Eventually consistent reads




       See Amazon’s site for read throughput pricing!
Other features

Integrates with Amazon Elastic MapReduce and
Hadoop.

Libraries, mappers and mocks for Django,
Erlang, Java, .NET, Node.js, Perl, PHP, Python &
Ruby.

Session based authentication using Amazon
Security Token Service

Monitoring via CloudWatch
DynamoDB Semantics

Tables, item & attributes

Items are indexed by primary key (single hash
and composite keys)

Items are a collection of attributes and attributes
have a key and value.

Unlimited number of attributes up to 64k total.
Simple API calls

 CreateTable       PutItem
UpdateTable        GetItem
 DeleteTable      UpdateItem
DescribeTable     DeleteItem
  ListTables

   Query          BatchGetItem
   Scan          BatchWriteItem
Kiva loan browser




http://kivabrowser.elasticbeanstalk.com
CRUD items
Connect to DynamoDB
New Loan
Show Loan
All/Filter Loans
CloudSpokes Challenge
Flickr on DynamoDB




 Wcheung (Canada) submitted a Grails application that caches Flickr photos in
Amazon DynamoDB. You can then search for cached feed entries by primary key
  (author + published date/time range) or by table scan. You can also “like” a
 photo, resulting in the atomic “like” counter for the item in DynamoDB getting
                                   incremented.

        http://screencast.com/t/MAVgm7xeqDpr
Posterity




Mbleigh (US) submitted a simple, barebones Twitter-esque service created in
Ruby using Sinatra. It is far from complete but uses a number of DynamoDB's
 key features including Hash/Range Keys and Atomic Set Push Operations.

  http://www.screencast.com/t/me8hW27MYs3x
DynamoDB Task Manager




Darthdeus (Czech Republic) wrote his app in Ruby using Sinatra. It uses a custom
ORM he wrote called DynamoRecord to access DynamoDB. His main idea was to
 get at least some of the ActiveRecord-ish API to DynamoDB using some basic
                                metaprogramming

 http://www.youtube.com/watch?v=9tOzaDPP39I
Simple Sur vey




  Peakpado (US) created an application using Ruby on Rails. For each table he
created a sophisticated hask/range key model class which resulted in an API very
                     similar to ActiveRecord for DynamoDB.

         http://screencast.com/t/ri1XkMxGcpnS
Data Sets for Mumbai




 Romin (India) developed an API that exposes data sets of Mumbai city in JSON
format. The solution uses Amazon DynamoDB for storing the data and a NodeJS
application that exposes the REST interface and talks to Amazon DynamoDB via
                           a backend Java application.
Thanks!

Jeff Douglas
CloudSpokes
Community Architect

@jeffdonthemic
jeff@cloudspokes.com



             http://www.cloudspokes.com
              http://blog.jeffdouglas.com
1 of 40

Recommended

Dynamo db pros and cons by
Dynamo db  pros and consDynamo db  pros and cons
Dynamo db pros and consSaniya Khalsa
27.1K views5 slides
Azure CosmosDb by
Azure CosmosDbAzure CosmosDb
Azure CosmosDbMarco Parenzan
570 views33 slides
Production NoSQL in an Hour: Introduction to Amazon DynamoDB (DAT101) | AWS r... by
Production NoSQL in an Hour: Introduction to Amazon DynamoDB (DAT101) | AWS r...Production NoSQL in an Hour: Introduction to Amazon DynamoDB (DAT101) | AWS r...
Production NoSQL in an Hour: Introduction to Amazon DynamoDB (DAT101) | AWS r...Amazon Web Services
4K views76 slides
Introducing DynamoDB by
Introducing DynamoDBIntroducing DynamoDB
Introducing DynamoDBAmazon Web Services
3.6K views83 slides
NoSQL: Why, When, and How by
NoSQL: Why, When, and HowNoSQL: Why, When, and How
NoSQL: Why, When, and HowBigBlueHat
6.2K views123 slides
Azure CosmosDb - Where we are by
Azure CosmosDb - Where we areAzure CosmosDb - Where we are
Azure CosmosDb - Where we areMarco Parenzan
121 views42 slides

More Related Content

What's hot

Compare DynamoDB vs. MongoDB by
Compare DynamoDB vs. MongoDBCompare DynamoDB vs. MongoDB
Compare DynamoDB vs. MongoDBAmar Das
9.4K views19 slides
Autoscale DynamoDB with Dynamic DynamoDB by
Autoscale DynamoDB with Dynamic DynamoDBAutoscale DynamoDB with Dynamic DynamoDB
Autoscale DynamoDB with Dynamic DynamoDBSebastian Dahlgren
4.3K views12 slides
Application design for the cloud using AWS by
Application design for the cloud using AWSApplication design for the cloud using AWS
Application design for the cloud using AWSJonathan Holloway
326 views31 slides
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams... by
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...Amazon Web Services
2.3K views57 slides
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB by
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAmazon Web Services
7.7K views81 slides
Data Warehousing with Amazon Redshift by
Data Warehousing with Amazon RedshiftData Warehousing with Amazon Redshift
Data Warehousing with Amazon RedshiftAmazon Web Services
4.4K views48 slides

What's hot(20)

Compare DynamoDB vs. MongoDB by Amar Das
Compare DynamoDB vs. MongoDBCompare DynamoDB vs. MongoDB
Compare DynamoDB vs. MongoDB
Amar Das9.4K views
Application design for the cloud using AWS by Jonathan Holloway
Application design for the cloud using AWSApplication design for the cloud using AWS
Application design for the cloud using AWS
Jonathan Holloway326 views
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams... by Amazon Web Services
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...
(SDD424) Simplifying Scalable Distributed Applications Using DynamoDB Streams...
Amazon Web Services2.3K views
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB by Amazon Web Services
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDBAWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
AWS December 2015 Webinar Series - Design Patterns using Amazon DynamoDB
Amazon Web Services7.7K views
Apache MetaModel - unified access to all your data points by Kasper Sørensen
Apache MetaModel - unified access to all your data pointsApache MetaModel - unified access to all your data points
Apache MetaModel - unified access to all your data points
Kasper Sørensen2.3K views
The other Apache Technologies your Big Data solution needs by gagravarr
The other Apache Technologies your Big Data solution needsThe other Apache Technologies your Big Data solution needs
The other Apache Technologies your Big Data solution needs
gagravarr983 views
Amazon RedShift - Ianni Vamvadelis by huguk
Amazon RedShift - Ianni VamvadelisAmazon RedShift - Ianni Vamvadelis
Amazon RedShift - Ianni Vamvadelis
huguk3K views
ArangoDB – A different approach to NoSQL by ArangoDB Database
ArangoDB – A different approach to NoSQLArangoDB – A different approach to NoSQL
ArangoDB – A different approach to NoSQL
ArangoDB Database13.7K views
Best practices for Data warehousing with Amazon Redshift - AWS PS Summit Canb... by Amazon Web Services
Best practices for Data warehousing with Amazon Redshift - AWS PS Summit Canb...Best practices for Data warehousing with Amazon Redshift - AWS PS Summit Canb...
Best practices for Data warehousing with Amazon Redshift - AWS PS Summit Canb...
Microsoft's Big Play for Big Data- Visual Studio Live! NY 2012 by Andrew Brust
Microsoft's Big Play for Big Data- Visual Studio Live! NY 2012Microsoft's Big Play for Big Data- Visual Studio Live! NY 2012
Microsoft's Big Play for Big Data- Visual Studio Live! NY 2012
Andrew Brust1.3K views
Cloud Computing and the Microsoft Developer - A Down-to-Earth Analysis by Andrew Brust
Cloud Computing and the Microsoft Developer - A Down-to-Earth AnalysisCloud Computing and the Microsoft Developer - A Down-to-Earth Analysis
Cloud Computing and the Microsoft Developer - A Down-to-Earth Analysis
Andrew Brust1.9K views

Similar to Gluecon 2012 - DynamoDB

Nosql seminar by
Nosql seminarNosql seminar
Nosql seminarShreyashkumar Nangnurwar
3.3K views40 slides
Big data vahidamiri-tabriz-13960226-datastack.ir by
Big data vahidamiri-tabriz-13960226-datastack.irBig data vahidamiri-tabriz-13960226-datastack.ir
Big data vahidamiri-tabriz-13960226-datastack.irdatastack
287 views44 slides
Front Range PHP NoSQL Databases by
Front Range PHP NoSQL DatabasesFront Range PHP NoSQL Databases
Front Range PHP NoSQL DatabasesJon Meredith
2.3K views50 slides
JS App Architecture by
JS App ArchitectureJS App Architecture
JS App ArchitectureCorey Butler
911 views19 slides
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ... by
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...Precisely
855 views22 slides
Rolling With Riak by
Rolling With RiakRolling With Riak
Rolling With RiakJohn Lynch
4K views23 slides

Similar to Gluecon 2012 - DynamoDB(20)

Big data vahidamiri-tabriz-13960226-datastack.ir by datastack
Big data vahidamiri-tabriz-13960226-datastack.irBig data vahidamiri-tabriz-13960226-datastack.ir
Big data vahidamiri-tabriz-13960226-datastack.ir
datastack287 views
Front Range PHP NoSQL Databases by Jon Meredith
Front Range PHP NoSQL DatabasesFront Range PHP NoSQL Databases
Front Range PHP NoSQL Databases
Jon Meredith2.3K views
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ... by Precisely
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...
Big Data Goes Airborne. Propelling Your Big Data Initiative with Ironcluster ...
Precisely855 views
Rolling With Riak by John Lynch
Rolling With RiakRolling With Riak
Rolling With Riak
John Lynch4K views
Getting Started with Big Data and HPC in the Cloud - August 2015 by Amazon Web Services
Getting Started with Big Data and HPC in the Cloud - August 2015Getting Started with Big Data and HPC in the Cloud - August 2015
Getting Started with Big Data and HPC in the Cloud - August 2015
Amazon Web Services9.9K views
NoSQL by dbulic
NoSQLNoSQL
NoSQL
dbulic1.4K views
Introduction to NoSql by Omid Vahdaty
Introduction to NoSqlIntroduction to NoSql
Introduction to NoSql
Omid Vahdaty321 views
Navigating NoSQL in cloudy skies by shnkr_rmchndrn
Navigating NoSQL in cloudy skiesNavigating NoSQL in cloudy skies
Navigating NoSQL in cloudy skies
shnkr_rmchndrn863 views
AWS Webcast - Build high-scale applications with Amazon DynamoDB by Amazon Web Services
AWS Webcast - Build high-scale applications with Amazon DynamoDBAWS Webcast - Build high-scale applications with Amazon DynamoDB
AWS Webcast - Build high-scale applications with Amazon DynamoDB
Amazon Web Services6.1K views
Nonrelational Databases by Udi Bauman
Nonrelational DatabasesNonrelational Databases
Nonrelational Databases
Udi Bauman5.8K views
Couchbase - Yet Another Introduction by Kelum Senanayake
Couchbase - Yet Another IntroductionCouchbase - Yet Another Introduction
Couchbase - Yet Another Introduction
Kelum Senanayake14.1K views

More from Jeff Douglas

Forcelandia 2015 by
Forcelandia 2015Forcelandia 2015
Forcelandia 2015Jeff Douglas
868 views25 slides
CloudSpokes Overview by
CloudSpokes OverviewCloudSpokes Overview
CloudSpokes OverviewJeff Douglas
945 views27 slides
SD DUG Salesforce Lightning Week by
SD DUG Salesforce Lightning WeekSD DUG Salesforce Lightning Week
SD DUG Salesforce Lightning WeekJeff Douglas
875 views24 slides
Building Command-line Tools with the Tooling API by
Building Command-line Tools with the Tooling APIBuilding Command-line Tools with the Tooling API
Building Command-line Tools with the Tooling APIJeff Douglas
1.7K views14 slides
Build Consumer-Facing Apps with Heroku Connect by
Build Consumer-Facing Apps with Heroku ConnectBuild Consumer-Facing Apps with Heroku Connect
Build Consumer-Facing Apps with Heroku ConnectJeff Douglas
25K views17 slides
Build your API with Force.com and Heroku by
Build your API with Force.com and HerokuBuild your API with Force.com and Heroku
Build your API with Force.com and HerokuJeff Douglas
18.5K views20 slides

More from Jeff Douglas(10)

CloudSpokes Overview by Jeff Douglas
CloudSpokes OverviewCloudSpokes Overview
CloudSpokes Overview
Jeff Douglas945 views
SD DUG Salesforce Lightning Week by Jeff Douglas
SD DUG Salesforce Lightning WeekSD DUG Salesforce Lightning Week
SD DUG Salesforce Lightning Week
Jeff Douglas875 views
Building Command-line Tools with the Tooling API by Jeff Douglas
Building Command-line Tools with the Tooling APIBuilding Command-line Tools with the Tooling API
Building Command-line Tools with the Tooling API
Jeff Douglas1.7K views
Build Consumer-Facing Apps with Heroku Connect by Jeff Douglas
Build Consumer-Facing Apps with Heroku ConnectBuild Consumer-Facing Apps with Heroku Connect
Build Consumer-Facing Apps with Heroku Connect
Jeff Douglas25K views
Build your API with Force.com and Heroku by Jeff Douglas
Build your API with Force.com and HerokuBuild your API with Force.com and Heroku
Build your API with Force.com and Heroku
Jeff Douglas18.5K views
Creating HTML5 Applications with jQuery Mobile, Ruby and Database.com by Jeff Douglas
Creating HTML5 Applications with jQuery Mobile, Ruby and Database.comCreating HTML5 Applications with jQuery Mobile, Ruby and Database.com
Creating HTML5 Applications with jQuery Mobile, Ruby and Database.com
Jeff Douglas2.7K views
Using Node.js for Mocking Apex Web Services by Jeff Douglas
Using Node.js for Mocking Apex Web ServicesUsing Node.js for Mocking Apex Web Services
Using Node.js for Mocking Apex Web Services
Jeff Douglas1.8K views
Connect Your Clouds with Force.com by Jeff Douglas
Connect Your Clouds with Force.comConnect Your Clouds with Force.com
Connect Your Clouds with Force.com
Jeff Douglas1.7K views
Architecting in the Cloud: Choosing the Right Technologies for your Solution by Jeff Douglas
Architecting in the Cloud: Choosing the Right Technologies for your SolutionArchitecting in the Cloud: Choosing the Right Technologies for your Solution
Architecting in the Cloud: Choosing the Right Technologies for your Solution
Jeff Douglas1K views

Recently uploaded

Melek BEN MAHMOUD.pdf by
Melek BEN MAHMOUD.pdfMelek BEN MAHMOUD.pdf
Melek BEN MAHMOUD.pdfMelekBenMahmoud
14 views1 slide
Business Analyst Series 2023 - Week 3 Session 5 by
Business Analyst Series 2023 -  Week 3 Session 5Business Analyst Series 2023 -  Week 3 Session 5
Business Analyst Series 2023 - Week 3 Session 5DianaGray10
300 views20 slides
Serverless computing with Google Cloud (2023-24) by
Serverless computing with Google Cloud (2023-24)Serverless computing with Google Cloud (2023-24)
Serverless computing with Google Cloud (2023-24)wesley chun
11 views33 slides
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f... by
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...TrustArc
11 views29 slides
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas... by
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...Bernd Ruecker
40 views69 slides
Special_edition_innovator_2023.pdf by
Special_edition_innovator_2023.pdfSpecial_edition_innovator_2023.pdf
Special_edition_innovator_2023.pdfWillDavies22
18 views6 slides

Recently uploaded(20)

Business Analyst Series 2023 - Week 3 Session 5 by DianaGray10
Business Analyst Series 2023 -  Week 3 Session 5Business Analyst Series 2023 -  Week 3 Session 5
Business Analyst Series 2023 - Week 3 Session 5
DianaGray10300 views
Serverless computing with Google Cloud (2023-24) by wesley chun
Serverless computing with Google Cloud (2023-24)Serverless computing with Google Cloud (2023-24)
Serverless computing with Google Cloud (2023-24)
wesley chun11 views
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f... by TrustArc
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc11 views
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas... by Bernd Ruecker
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...
Bernd Ruecker40 views
Special_edition_innovator_2023.pdf by WillDavies22
Special_edition_innovator_2023.pdfSpecial_edition_innovator_2023.pdf
Special_edition_innovator_2023.pdf
WillDavies2218 views
PharoJS - Zürich Smalltalk Group Meetup November 2023 by Noury Bouraqadi
PharoJS - Zürich Smalltalk Group Meetup November 2023PharoJS - Zürich Smalltalk Group Meetup November 2023
PharoJS - Zürich Smalltalk Group Meetup November 2023
Noury Bouraqadi132 views
Piloting & Scaling Successfully With Microsoft Viva by Richard Harbridge
Piloting & Scaling Successfully With Microsoft VivaPiloting & Scaling Successfully With Microsoft Viva
Piloting & Scaling Successfully With Microsoft Viva
HTTP headers that make your website go faster - devs.gent November 2023 by Thijs Feryn
HTTP headers that make your website go faster - devs.gent November 2023HTTP headers that make your website go faster - devs.gent November 2023
HTTP headers that make your website go faster - devs.gent November 2023
Thijs Feryn22 views
Future of AR - Facebook Presentation by ssuserb54b561
Future of AR - Facebook PresentationFuture of AR - Facebook Presentation
Future of AR - Facebook Presentation
ssuserb54b56115 views
6g - REPORT.pdf by Liveplex
6g - REPORT.pdf6g - REPORT.pdf
6g - REPORT.pdf
Liveplex10 views
Data Integrity for Banking and Financial Services by Precisely
Data Integrity for Banking and Financial ServicesData Integrity for Banking and Financial Services
Data Integrity for Banking and Financial Services
Precisely25 views
Igniting Next Level Productivity with AI-Infused Data Integration Workflows by Safe Software
Igniting Next Level Productivity with AI-Infused Data Integration Workflows Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Safe Software280 views
Unit 1_Lecture 2_Physical Design of IoT.pdf by StephenTec
Unit 1_Lecture 2_Physical Design of IoT.pdfUnit 1_Lecture 2_Physical Design of IoT.pdf
Unit 1_Lecture 2_Physical Design of IoT.pdf
StephenTec12 views

Gluecon 2012 - DynamoDB

  • 1. ¡Ay, caramba! Wrestle Your NoSQL Data with DynamoDB Je ff Dougl a s @je ff do n th em ic C lo udSp ok es C ommun it y Arch itec t
  • 2. Rambling Talk Roadmap Short NoSQL overview (thanks Max @ 10gen!) Why NoSQL database are like Mexican Wrestlers Amazon DynamoDB in depth Amazon DynamoDB demo and code CloudSpokes challenge submissions for “Build an #Awesome Demo with Amazon DynamoDB”
  • 3. Times they are a-changin’ Cloud applications and APIs need to be fast, flexible and scalable. RDBMS typically do not scale well for certain data-intensive application. NoSQL is cloud friendly. “NoSQL is a rebellion against the DBAs who prevent us from doing shit.” - James Governor, Gluecon 2012
  • 4. Why is NoSQL #awesome? Developed to manage large volumes of data that do not necessarily follow a fixed schema Great for heavy read/write workloads Simple to setup, configure and administer Distributed, fault tolerant architecture Scale out not up Specialized database for the right task
  • 5. Key NoSQL differences Do not use SQL as a query language Dynamic & schema-less Non-relational, no JOIN operations No complex transactions May not give full ACID guarantees; eventually consistent instead. Performance and real-time nature is more important than consistency.
  • 6. NoSQL databases are “different”
  • 7. NoSQL database types Document store (MongoDB, CouchDB) A document-oriented database that stores, retrieves, and manages semi structured data including XML, YAML, JSON and binary (PDF, DOC) Key-value store (Cassandra, Redis) Stores scheme-less data referenced by a simple key value Graph database (Neo4j, FlockDB) Stores the relationship of data as a graph (social relations, network topologies)
  • 8. How to choose? With all of the different NoSQL database types, how do you choose the “best” one?
  • 9. El Toro Más Macho MongoDB Stores structured data as JSON-like documents. Ad hoc queries, indexing, master-slave replication, sharding, server-side JavaScript execution All the “cool kids” are using it. Node.js + MongoDB = WINNING!
  • 10. Muy Guapo Couchbase JSON Document store Embedded CouchDB with caching, clustering and high-performance storage management components. JavaScript as its query language and HTTP for an API Serve HTML and JavaScript-based “CouchApps”
  • 11. El Matador Misterio Redis What exactly is redis? MAGIC! By definition, it’s an in-memory, key-value data store with optional durability. Data model includes list of string, sets of strings, sorted sets of strings & hashes. Awesome at doing set comparisons.
  • 12. Comando Loco Apache Hadoop Fast, reliable analysis of both structured data and complex data. Derived from Google's MapReduce and File System (GFS) papers. Yahoo is one of the main contributors. Reliable data storage using the Hadoop Distributed File System (HDFS) and high- performance parallel data processing using MapReduce.
  • 13. El Jefe Supremo Apache Cassandra Massively scalable key-value store initially developed by Facebook. BigTable data model (nested hashes) running on an Amazon Dynamo-like infrastructure. Has some RDBMS “feel” with column families that make it it a hybrid column/row store. No single point of failure, fault-tolerant multi data center replication, MapReduce support. CQL (Cassandra Query Language)
  • 16. ¡Hola DynamoDB Amazon DynamoDB is a fast, fully managed key-value database service that scales seamlessly with extremely low latency and predictable performance. Store and retrieve any amount of data Serve any level of request traffic Hands off administration Pay for throughput and not storage
  • 17. ¡No! administración No hardware or software provisioning, setup and configuration, software patching, or partitioning data over multiple instances and regions. Specify the request throughput for your table and in the background, Amazon handles the provisioning of resources to meet the requested throughput rate. Automatically partitions/re-partitions data and provisions additional server capacity based upon table size & throughput. Synchronously replicates data across multiple facilities in an AWS Region giving you high availability and data durability.
  • 18. Muy rápido Consistent, predictable performance Runs on a new solid state disk (SSD) architecture for low-latency response times. Read latencies average less than 5 milliseconds, and write latencies average less than 10 milliseconds.
  • 19. Muy Escalable No table size limits (adiós SimpleDB?) No downtime when scaling up or down Unlimited storage Automatically scale machine resources in response to increases in database traffic without the need of client-side partitioning.
  • 20. Modelo de datos flexible Flexible data model with familiar tables, items and key-value pairs. Schema-less document storage. Each item can have different attributes. Easy to create and modify documents. Simple API. No cross-table joins. Use composite keys to model relationships.
  • 21. Duradero Consistent, disk-only writes Atomic increment/decrement (w/single API call) Optimistic concurrency control (aka conditional writes & updates) Item level transactions (even in bulk) Automatic and synchronous replication across data centers and availability zones.
  • 22. Costos? Pay for throughput and not storage. Priced per hour of provisioned read/write throughput Scales up and down well with a free tier
  • 23. Write throughput Write throughput Unit = size of item x writes/second $0.01 per hour for 10 write units
  • 24. Read throughput Strongly consistent reads (mucho dinero) Eventually consistent reads See Amazon’s site for read throughput pricing!
  • 25. Other features Integrates with Amazon Elastic MapReduce and Hadoop. Libraries, mappers and mocks for Django, Erlang, Java, .NET, Node.js, Perl, PHP, Python & Ruby. Session based authentication using Amazon Security Token Service Monitoring via CloudWatch
  • 26. DynamoDB Semantics Tables, item & attributes Items are indexed by primary key (single hash and composite keys) Items are a collection of attributes and attributes have a key and value. Unlimited number of attributes up to 64k total.
  • 27. Simple API calls CreateTable PutItem UpdateTable GetItem DeleteTable UpdateItem DescribeTable DeleteItem ListTables Query BatchGetItem Scan BatchWriteItem
  • 35. Flickr on DynamoDB Wcheung (Canada) submitted a Grails application that caches Flickr photos in Amazon DynamoDB. You can then search for cached feed entries by primary key (author + published date/time range) or by table scan. You can also “like” a photo, resulting in the atomic “like” counter for the item in DynamoDB getting incremented. http://screencast.com/t/MAVgm7xeqDpr
  • 36. Posterity Mbleigh (US) submitted a simple, barebones Twitter-esque service created in Ruby using Sinatra. It is far from complete but uses a number of DynamoDB's key features including Hash/Range Keys and Atomic Set Push Operations. http://www.screencast.com/t/me8hW27MYs3x
  • 37. DynamoDB Task Manager Darthdeus (Czech Republic) wrote his app in Ruby using Sinatra. It uses a custom ORM he wrote called DynamoRecord to access DynamoDB. His main idea was to get at least some of the ActiveRecord-ish API to DynamoDB using some basic metaprogramming http://www.youtube.com/watch?v=9tOzaDPP39I
  • 38. Simple Sur vey Peakpado (US) created an application using Ruby on Rails. For each table he created a sophisticated hask/range key model class which resulted in an API very similar to ActiveRecord for DynamoDB. http://screencast.com/t/ri1XkMxGcpnS
  • 39. Data Sets for Mumbai Romin (India) developed an API that exposes data sets of Mumbai city in JSON format. The solution uses Amazon DynamoDB for storing the data and a NodeJS application that exposes the REST interface and talks to Amazon DynamoDB via a backend Java application.

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n
  34. \n
  35. \n
  36. \n
  37. \n
  38. \n
  39. \n
  40. \n