SlideShare una empresa de Scribd logo
1 de 20
Descargar para leer sin conexión
Getting started with Riak
NoSQL Live · Boston, MA · March 2010



                Rusty Klophaus (@rklophaus)
                Sr. Engineer | Basho Technologies
                http://www.basho.com
                rusty@basho.com
Introductions
Rusty Klophaus                  Bryan Fink
 • Senior Engineer                • Engineering Manager
 • Joined in August ‘09           • Joined in February ’08




Andy Gross                      Mark Phillips
 • VP of Engineering              • Community Manager
 • Joined in December ’07         • Joined in April ’08



                            2
Follow the team:
 @basho/team




       3
There are 47 different
NoSQL projects...

Where does Riak fit in?




                   4
Riak is a Dynamo-inspired
key/value datastore
built to scale predictably and easily.




                  5
Riak is a Dynamo-inspired
key/value datastore
built to scale predictably and easily.
     Your ops guy: calm, relaxed, and wearing a party hat.
What characteristics of Riak become
important at different cluster sizes?




                  7
Single Box Riak



• NoSQL - Key/Value, Flexible Schema
• Clients in Ruby, Python, Javascript, Java, PHP, Erlang
• Development Interface === Production Interface
• Configurable Buckets - “A Profile is not an .mp3”
• Links - Lightweight Data Relations

                          8
Small Riak Cluster (~3 boxes)




• Distributed Queries for Performance / Capacity
• Javascript-based Map/Reduce (mini-Hadoop)
• Well-Behaved HTTP
 • nginx proxy config - http://gist.github.com/323048


                           9
Large Riak Cluster (10+ boxes)




•   Homogenous - No special nodes
•   Laugh in the face of machine failure
•   Scale by adding machines
•   Self-Contained Installation

                          10
Enterprise ($$$ / ~10’s of boxes)




•   On-Call Support 24x7x365
•   Management Tools
•   SNMP Monitoring
•   Multi-site Replication

                         11
Enterprise ($$$ / ~10’s of boxes)




•   On-Call Support 24x7x365
•   Management Tools
•   SNMP Monitoring
•   Multi-site Replication

                         12
Tutorial
Get Riak
Connect with a Client
Store Data
Store an Object with Links
Linkwalking
Map/Reduce

                        13
Get Riak
Download
 http://downloads.basho.com/riak

Start Riak
 cd riak
 bin/riak start




                      14
Connect with Python
# Code is in ./riak/client_lib/python
import riak

# Connect
client = riak.RiakClient('127.0.0.1', 8098)




                      15
Store Data
mybucket = client.bucket('mybucket')

# Create an object...
obj = mybucket.new('myobject')
obj.set_data({ 'foo' : 1, 'bar' : 2 })
obj.store()

# Read the object...
obj = mybucket.get('myobject')
print obj.get_data()

# Or, open a web browser...
http://127.0.0.1:8098/riak/mybucket/myobject


                      16
Store an Object with Links
bands = client.bucket('bands')
albums = client.bucket('albums')
members = client.bucket('members')

# Store a band, link to album and members...
obj = bands.new('Winger') 
    .add_link(albums.new('Pull', 1275922).store()) 
    .add_link(albums.new('IV', 542731).store()) 
    .add_link(albums.new('Karma', 200170).store()) 
    .add_link(members.new('Kip Winger').store()) 
    .add_link(members.new('Reb Beach').store()) 
    .add_link(members.new('John Roth').store()) 
    .add_link(members.new('Rod M.').store()) 
    .store()




                          17
Linkwalking
# Get the albums...
albums = obj.link('albums').run()

# Get the songs (assumes data is present)...
songs = obj.link('albums').link('songs').run()

# Get the members...
members = riak.MapReduce(client) 
    .add('bands', 'Winger') 
    .link('members') 
    .run()




                      18
Map/Reduce
# Count the number of sales...
result = obj 
    .link('albums') 
    .map("function(v) { return [v.values[0].data]; }") 
    .reduce("Riak.reduceSum") 
    .run()




                           19
Thanks! / Questions?
Questions?
 • riak-users@lists.basho.com (Public Mailing List)
 • riak@basho.com (Core Riak Team)
 • Follow @basho/team (Basho Twitter List)


Riak Resources
 • http://riak.basho.com
 • http://downloads.basho.com
 • ./riak/client_lib <--- Python, JS, Java, PHP libraries




                                  20

Más contenido relacionado

La actualidad más candente

La actualidad más candente (11)

Operationalizing MongoDB at AOL
Operationalizing MongoDB at AOLOperationalizing MongoDB at AOL
Operationalizing MongoDB at AOL
 
Kings fund - implementing Hyku
Kings fund - implementing HykuKings fund - implementing Hyku
Kings fund - implementing Hyku
 
Web Ninja
Web NinjaWeb Ninja
Web Ninja
 
StackStormを1年間データ基盤で使ってみてぶつかったトラブルとその解決策の共有
StackStormを1年間データ基盤で使ってみてぶつかったトラブルとその解決策の共有StackStormを1年間データ基盤で使ってみてぶつかったトラブルとその解決策の共有
StackStormを1年間データ基盤で使ってみてぶつかったトラブルとその解決策の共有
 
Voldemortの紹介
Voldemortの紹介Voldemortの紹介
Voldemortの紹介
 
Log analysis using Logstash,ElasticSearch and Kibana
Log analysis using Logstash,ElasticSearch and KibanaLog analysis using Logstash,ElasticSearch and Kibana
Log analysis using Logstash,ElasticSearch and Kibana
 
Ruby on Rails Workshop
Ruby on Rails WorkshopRuby on Rails Workshop
Ruby on Rails Workshop
 
Benchmarking Redis by itself and versus other NoSQL databases
Benchmarking Redis by itself and versus other NoSQL databasesBenchmarking Redis by itself and versus other NoSQL databases
Benchmarking Redis by itself and versus other NoSQL databases
 
OpenStack Summit Hong Kong
OpenStack Summit Hong KongOpenStack Summit Hong Kong
OpenStack Summit Hong Kong
 
Hidden gems in SXA that you might not be aware of
Hidden gems in SXA that you might not be aware ofHidden gems in SXA that you might not be aware of
Hidden gems in SXA that you might not be aware of
 
Big data workloads using Apache Sparkon HDInsight
Big data workloads using Apache Sparkon HDInsightBig data workloads using Apache Sparkon HDInsight
Big data workloads using Apache Sparkon HDInsight
 

Similar a Getting Started with Riak - NoSQL Live 2010 - Boston

Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)
Sean Cribbs
 
Riak seattle-meetup-august
Riak seattle-meetup-augustRiak seattle-meetup-august
Riak seattle-meetup-august
pharkmillups
 

Similar a Getting Started with Riak - NoSQL Live 2010 - Boston (20)

Riak from Small to Large
Riak from Small to LargeRiak from Small to Large
Riak from Small to Large
 
Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)
 
Riak - From Small to Large - StrangeLoop
Riak - From Small to Large - StrangeLoopRiak - From Small to Large - StrangeLoop
Riak - From Small to Large - StrangeLoop
 
Riak - From Small to Large
Riak - From Small to LargeRiak - From Small to Large
Riak - From Small to Large
 
Riak seattle-meetup-august
Riak seattle-meetup-augustRiak seattle-meetup-august
Riak seattle-meetup-august
 
Icinga 2009 at OSMC
Icinga 2009 at OSMCIcinga 2009 at OSMC
Icinga 2009 at OSMC
 
Riak with Rails
Riak with RailsRiak with Rails
Riak with Rails
 
Adding Riak to your NoSQL Bag of Tricks
Adding Riak to your NoSQL Bag of TricksAdding Riak to your NoSQL Bag of Tricks
Adding Riak to your NoSQL Bag of Tricks
 
Dask: Scaling Python
Dask: Scaling PythonDask: Scaling Python
Dask: Scaling Python
 
Newer Yankee Workshop - NoSQL
Newer Yankee Workshop -  NoSQLNewer Yankee Workshop -  NoSQL
Newer Yankee Workshop - NoSQL
 
Introduction to Riak - Red Dirt Ruby Conf Training
Introduction to Riak - Red Dirt Ruby Conf TrainingIntroduction to Riak - Red Dirt Ruby Conf Training
Introduction to Riak - Red Dirt Ruby Conf Training
 
Australian OpenStack User Group August 2012: Chef for OpenStack
Australian OpenStack User Group August 2012: Chef for OpenStackAustralian OpenStack User Group August 2012: Chef for OpenStack
Australian OpenStack User Group August 2012: Chef for OpenStack
 
Monitoring Oracle Database Instances with Zabbix
Monitoring Oracle Database Instances with ZabbixMonitoring Oracle Database Instances with Zabbix
Monitoring Oracle Database Instances with Zabbix
 
MySQL Ecosystem in 2023 - FOSSASIA'23 - Alkin.pptx.pdf
MySQL Ecosystem in 2023 - FOSSASIA'23 - Alkin.pptx.pdfMySQL Ecosystem in 2023 - FOSSASIA'23 - Alkin.pptx.pdf
MySQL Ecosystem in 2023 - FOSSASIA'23 - Alkin.pptx.pdf
 
Ryan Armstrong - Monitoring More Than 6000 Devices in Zabbix | ZabConf2016
Ryan Armstrong - Monitoring More Than 6000 Devices in Zabbix | ZabConf2016Ryan Armstrong - Monitoring More Than 6000 Devices in Zabbix | ZabConf2016
Ryan Armstrong - Monitoring More Than 6000 Devices in Zabbix | ZabConf2016
 
OpenStack Deployments with Chef
OpenStack Deployments with ChefOpenStack Deployments with Chef
OpenStack Deployments with Chef
 
Chef for OpenStack - OpenStack Fall 2012 Summit
Chef for OpenStack  - OpenStack Fall 2012 SummitChef for OpenStack  - OpenStack Fall 2012 Summit
Chef for OpenStack - OpenStack Fall 2012 Summit
 
Chef for OpenStack- Fall 2012.pdf
Chef for OpenStack- Fall 2012.pdfChef for OpenStack- Fall 2012.pdf
Chef for OpenStack- Fall 2012.pdf
 
MySQL Document Store
MySQL Document StoreMySQL Document Store
MySQL Document Store
 
Webinar - DreamObjects/Ceph Case Study
Webinar - DreamObjects/Ceph Case StudyWebinar - DreamObjects/Ceph Case Study
Webinar - DreamObjects/Ceph Case Study
 

Más de Rusty Klophaus

Más de Rusty Klophaus (7)

Everybody Polyglot! - Cross-Language RPC with Erlang
Everybody Polyglot! - Cross-Language RPC with ErlangEverybody Polyglot! - Cross-Language RPC with Erlang
Everybody Polyglot! - Cross-Language RPC with Erlang
 
Winning the Erlang Edit•Build•Test Cycle
Winning the Erlang Edit•Build•Test CycleWinning the Erlang Edit•Build•Test Cycle
Winning the Erlang Edit•Build•Test Cycle
 
Querying Riak Just Got Easier - Introducing Secondary Indices
Querying Riak Just Got Easier - Introducing Secondary IndicesQuerying Riak Just Got Easier - Introducing Secondary Indices
Querying Riak Just Got Easier - Introducing Secondary Indices
 
Masterless Distributed Computing with Riak Core - EUC 2010
Masterless Distributed Computing with Riak Core - EUC 2010Masterless Distributed Computing with Riak Core - EUC 2010
Masterless Distributed Computing with Riak Core - EUC 2010
 
Riak Core: Building Distributed Applications Without Shared State
Riak Core: Building Distributed Applications Without Shared StateRiak Core: Building Distributed Applications Without Shared State
Riak Core: Building Distributed Applications Without Shared State
 
Riak Search - Erlang Factory London 2010
Riak Search - Erlang Factory London 2010Riak Search - Erlang Factory London 2010
Riak Search - Erlang Factory London 2010
 
Riak Search - Berlin Buzzwords 2010
Riak Search - Berlin Buzzwords 2010Riak Search - Berlin Buzzwords 2010
Riak Search - Berlin Buzzwords 2010
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Último (20)

ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 

Getting Started with Riak - NoSQL Live 2010 - Boston

  • 1. Getting started with Riak NoSQL Live · Boston, MA · March 2010 Rusty Klophaus (@rklophaus) Sr. Engineer | Basho Technologies http://www.basho.com rusty@basho.com
  • 2. Introductions Rusty Klophaus Bryan Fink • Senior Engineer • Engineering Manager • Joined in August ‘09 • Joined in February ’08 Andy Gross Mark Phillips • VP of Engineering • Community Manager • Joined in December ’07 • Joined in April ’08 2
  • 3. Follow the team: @basho/team 3
  • 4. There are 47 different NoSQL projects... Where does Riak fit in? 4
  • 5. Riak is a Dynamo-inspired key/value datastore built to scale predictably and easily. 5
  • 6. Riak is a Dynamo-inspired key/value datastore built to scale predictably and easily. Your ops guy: calm, relaxed, and wearing a party hat.
  • 7. What characteristics of Riak become important at different cluster sizes? 7
  • 8. Single Box Riak • NoSQL - Key/Value, Flexible Schema • Clients in Ruby, Python, Javascript, Java, PHP, Erlang • Development Interface === Production Interface • Configurable Buckets - “A Profile is not an .mp3” • Links - Lightweight Data Relations 8
  • 9. Small Riak Cluster (~3 boxes) • Distributed Queries for Performance / Capacity • Javascript-based Map/Reduce (mini-Hadoop) • Well-Behaved HTTP • nginx proxy config - http://gist.github.com/323048 9
  • 10. Large Riak Cluster (10+ boxes) • Homogenous - No special nodes • Laugh in the face of machine failure • Scale by adding machines • Self-Contained Installation 10
  • 11. Enterprise ($$$ / ~10’s of boxes) • On-Call Support 24x7x365 • Management Tools • SNMP Monitoring • Multi-site Replication 11
  • 12. Enterprise ($$$ / ~10’s of boxes) • On-Call Support 24x7x365 • Management Tools • SNMP Monitoring • Multi-site Replication 12
  • 13. Tutorial Get Riak Connect with a Client Store Data Store an Object with Links Linkwalking Map/Reduce 13
  • 15. Connect with Python # Code is in ./riak/client_lib/python import riak # Connect client = riak.RiakClient('127.0.0.1', 8098) 15
  • 16. Store Data mybucket = client.bucket('mybucket') # Create an object... obj = mybucket.new('myobject') obj.set_data({ 'foo' : 1, 'bar' : 2 }) obj.store() # Read the object... obj = mybucket.get('myobject') print obj.get_data() # Or, open a web browser... http://127.0.0.1:8098/riak/mybucket/myobject 16
  • 17. Store an Object with Links bands = client.bucket('bands') albums = client.bucket('albums') members = client.bucket('members') # Store a band, link to album and members... obj = bands.new('Winger') .add_link(albums.new('Pull', 1275922).store()) .add_link(albums.new('IV', 542731).store()) .add_link(albums.new('Karma', 200170).store()) .add_link(members.new('Kip Winger').store()) .add_link(members.new('Reb Beach').store()) .add_link(members.new('John Roth').store()) .add_link(members.new('Rod M.').store()) .store() 17
  • 18. Linkwalking # Get the albums... albums = obj.link('albums').run() # Get the songs (assumes data is present)... songs = obj.link('albums').link('songs').run() # Get the members... members = riak.MapReduce(client) .add('bands', 'Winger') .link('members') .run() 18
  • 19. Map/Reduce # Count the number of sales... result = obj .link('albums') .map("function(v) { return [v.values[0].data]; }") .reduce("Riak.reduceSum") .run() 19
  • 20. Thanks! / Questions? Questions? • riak-users@lists.basho.com (Public Mailing List) • riak@basho.com (Core Riak Team) • Follow @basho/team (Basho Twitter List) Riak Resources • http://riak.basho.com • http://downloads.basho.com • ./riak/client_lib <--- Python, JS, Java, PHP libraries 20