Home
Explore
Submit Search
Upload
Login
Signup
Advertisement
CouchDB @ red dirt ruby conference
Report
leinweber
Follow
May. 6, 2010
•
0 likes
1 likes
×
Be the first to like this
Show More
•
786 views
views
×
Total views
0
On Slideshare
0
From embeds
0
Number of embeds
0
Check these out next
MongoDB .local London 2019: Tips and Tricks++ for Querying and Indexing MongoDB
MongoDB
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
MongoSF
FalcorJS
Mathieu Breton
MongoDB dessi-codemotion
Massimiliano Dessì
Inside MongoDB: the Internals of an Open-Source Database
Mike Dirolf
Potential Friend Finder
Richard Schneeman
CouchDB on Android
Sven Haiges
How to use MongoDB with CakePHP
ichikaway
1
of
48
Top clipped slide
CouchDB @ red dirt ruby conference
May. 6, 2010
•
0 likes
1 likes
×
Be the first to like this
Show More
•
786 views
views
×
Total views
0
On Slideshare
0
From embeds
0
Number of embeds
0
Download Now
Download to read offline
Report
Technology
My presentation of CouchDB at red dirt ruby conference May 6th 2010
leinweber
Follow
Advertisement
Advertisement
Advertisement
Recommended
Thoughts on MongoDB Analytics
rogerbodamer
898 views
•
43 slides
Underscore
Andries Nieuwenhuize
225 views
•
12 slides
Network analysis with Hadoop and Neo4j
fvanvollenhoven
4.7K views
•
20 slides
Jan Lehnardt Couch Db In A Real World Setting
George Ang
350 views
•
53 slides
NoSQL War Stories preso: Hadoop and Neo4j for networks
fvanvollenhoven
998 views
•
13 slides
The Ring programming language version 1.10 book - Part 56 of 212
Mahmoud Samir Fayed
14 views
•
10 slides
More Related Content
Slideshows for you
(20)
MongoDB .local London 2019: Tips and Tricks++ for Querying and Indexing MongoDB
MongoDB
•
385 views
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
MongoSF
•
2.9K views
FalcorJS
Mathieu Breton
•
33 views
MongoDB dessi-codemotion
Massimiliano Dessì
•
2.2K views
Inside MongoDB: the Internals of an Open-Source Database
Mike Dirolf
•
51.9K views
Potential Friend Finder
Richard Schneeman
•
1.1K views
CouchDB on Android
Sven Haiges
•
5.4K views
How to use MongoDB with CakePHP
ichikaway
•
16.4K views
MongoDB World 2019: Aggregation Pipeline Power++: How MongoDB 4.2 Pipeline Em...
MongoDB
•
796 views
Webinar: Replication and Replica Sets
MongoDB
•
3K views
A Taste of Python - Devdays Toronto 2009
Jordan Baker
•
1.3K views
Dive into kotlins coroutines
Freddie Wang
•
573 views
Kotlin coroutines
TSE-JU LIN(Louis)
•
901 views
MongoDB World 2019: How to Keep an Average API Response Time Less than 5ms wi...
MongoDB
•
401 views
(Ab)Using the MetaCPAN API for Fun and Profit
Olaf Alders
•
2.3K views
집단지성 프로그래밍 08-가격모델링
Kwang Woo NAM
•
2.7K views
mobl - model-driven engineering lecture
zefhemel
•
1.3K views
Programming Lisp Clojure - 2장 : 클로저 둘러보기
JangHyuk You
•
750 views
Super Advanced Python –act1
Ke Wei Louis
•
1.5K views
밑바닥부터 시작하는 의료 AI
NAVER Engineering
•
758 views
Similar to CouchDB @ red dirt ruby conference
(20)
Happy Go Programming
Lin Yo-An
•
5.6K views
SFScon17 - Patrick Puecher: "Exploring data with Elasticsearch and Kibana"
South Tyrol Free Software Conference
•
387 views
HTML5 and CSS3 Refresher
Ivano Malavolta
•
4.5K views
ELK Stack - Turn boring logfiles into sexy dashboard
Georg Sorst
•
5.4K views
Aggregation Framework MongoDB Days Munich
Norberto Leite
•
2K views
Tabledown
T.C. Chou
•
465 views
d3sparql.js demo at SWAT4LS 2014 in Berlin
Toshiaki Katayama
•
2.9K views
CouchDB at JAOO Århus 2009
Jason Davies
•
537 views
Webinar: Data Processing and Aggregation Options
MongoDB
•
12.9K views
Sassive Aggressive: Using Sass to Make Your Life Easier (Refresh Boston Version)
Adam Darowski
•
1.1K views
MongoDB
Steve Klabnik
•
528 views
Modeling JSON data for NoSQL document databases
Ryan CrawCour
•
803 views
The Aggregation Framework
MongoDB
•
1.7K views
Mongo db presentation
Julie Sommerville
•
565 views
Webinar: General Technical Overview of MongoDB for Dev Teams
MongoDB
•
4.8K views
KISSY 的昨天、今天与明天
tblanlan
•
971 views
kissy-past-now-future
yiming he
•
1.1K views
Latinoware
kchodorow
•
556 views
Programming with Python and PostgreSQL
Peter Eisentraut
•
52.2K views
Building Apps with MongoDB
Nate Abele
•
9.3K views
Advertisement
Recently uploaded
(20)
INT 1010 08-4.pdf
Luis R Castellanos
•
4 views
chatgpt-privacy and security.pptx
Deepak Kumar
•
7 views
INT 1010 04-5.pdf
Luis R Castellanos
•
4 views
Slide share
Vasuki Arumugam
•
0 views
Event Stream Processing with BeepBeep 3
Sylvain Hallé
•
0 views
COMPUTER PPT.pptx
ishaanshehrawat
•
2 views
us-19-Shortridge-Forsgren-Controlled-Chaos-the-Inevitable-Marriage-of-DevOps-...
CynthiaRothrock
•
1 view
INT 1010 03.pdf
Luis R Castellanos
•
4 views
What-is-Empowerment-Technology.etech.pptx
JeromePantonial
•
0 views
Intro_Net_91407.ppt
SuhailParakkal5
•
0 views
M. L. Boas-Mathematical Methods in the Physical Sciences - John Wiley.pdf
ngurahayuketutumiati1
•
0 views
Chapter 5 - Normalization of Database Tables.pdf
JervinCagaananSapidR
•
3 views
k8s_dev.pdf
Christoph Zimmermann
•
10 views
Final Project Presentation.ppt
RogerBarrow2
•
0 views
Biodiesel From waste frying oil
akhileshtiwari846743
•
4 views
INT 1010 05-3.pdf
Luis R Castellanos
•
5 views
LISA EVO-X Pitch Deck
LEX101Labs
•
0 views
plantilla-cv-animado (2).pptx
LeidyMungua
•
0 views
Unit - 11 File Management.pptx
SatephwarGaming
•
0 views
different topics blogging articles.
AishaSajidAishaSajid
•
0 views
CouchDB @ red dirt ruby conference
couchdb, ruby, and you.
will leinweber — bitfission.com — merge.fm — @leinweber
will leinweber
will leinweber — bitfission.com — merge.fm — @leinweber
couchdb
will leinweber — bitfission.com — merge.fm — @leinweber
will leinweber —
bitfission.com — merge.fm — @leinweber
will leinweber —
bitfission.com — merge.fm — @leinweber
documents
will leinweber — bitfission.com — merge.fm — @leinweber
json
will leinweber — bitfission.com — merge.fm — @leinweber
rich documents
will leinweber — bitfission.com — merge.fm — @leinweber
{
"_id": "will", "_rev": "3-4352629382", "fullname": "Will Leinweber", "email": "will@bitfission.com", "sites": [ {"blog": "bitfission.com", "hits": 42}, {"github": "github.com/will"}, {"twitter": "twitter.com/leinweber"}, {"company": "merge.fm"} ] } will leinweber — bitfission.com — merge.fm — @leinweber
schemaless
will leinweber — bitfission.com — merge.fm — @leinweber
http api
will leinweber — bitfission.com — merge.fm — @leinweber
restful
will leinweber — bitfission.com — merge.fm — @leinweber
~% curl localhost:5984/appdb/docid {"_id":"docid","_rev":"2-3779119708","look":"at
all this data","its_awesome":true} will leinweber — bitfission.com — merge.fm — @leinweber
~% curl localhost:5984/appdb/docid
-i HTTP/1.1 200 OK Server: CouchDB/0.11.0 (Erlang OTP/R13B) Etag: "2-3779119708" Date: Wed, 28 Apr 2010 06:46:42 GMT Content-Type: text/plain;charset=utf-8 Content-Length: 83 Cache-Control: must-revalidate will leinweber — bitfission.com — merge.fm — @leinweber
caching
will leinweber — bitfission.com — merge.fm — @leinweber
clustering
will leinweber — bitfission.com — merge.fm — @leinweber
replication
will leinweber — bitfission.com — merge.fm — @leinweber
couchapps!
will leinweber — bitfission.com — merge.fm — @leinweber
views
will leinweber — bitfission.com — merge.fm — @leinweber
javascript map/reduce
will leinweber — bitfission.com — merge.fm — @leinweber
map will
leinweber — bitfission.com — merge.fm — @leinweber
bit.ly/jscouchdb example
will leinweber — bitfission.com — merge.fm — @leinweber
{"_id":1,"name":"fish.jpg","user":"bob","camera":"nikon",
"info":{"width":100,"height":200,"size":12345},"tags":["tuna","shark"]} {"_id":2,"name":"trees.jpg","user":"john","camera":"canon", "info":{"width":30,"height":250,"size":32091},"tags":["oak"]} {"_id":3,"name":"snow.png","user":"john","camera":"canon", "info":{"width":64,"height":64,"size":1253},"tags":["tahoe","powder"]} {"_id":4,"name":"hawaii.png","user":"john","camera":"nikon", "info":{"width":128,"height":64,"size":92834},"tags":["maui","tuna"]} {"_id":5,"name":"hawaii.gif","user":"bob","camera":"canon", "info":{"width":320,"height":128,"size":49287},"tags":["maui"]} {"_id":6,"name":"island.gif","user":"zztop","camera":"nikon", "info":{"width":640,"height":480,"size":50398},"tags":["maui"]} will leinweber — bitfission.com — merge.fm — @leinweber
function(doc) {
emit(doc.user, null); } { "total_rows": 6, "rows": [ {"id":"1","key":"bob","value":null}, {"id":"5","key":"bob","value":null}, {"id":"2","key":"john","value":null}, {"id":"3","key":"john","value":null}, {"id":"4","key":"john","value":null}, {"id":"6","key":"zztop","value":null} ] } will leinweber — bitfission.com — merge.fm — @leinweber
function(doc) {
emit(doc.name.match(/w+.(w{3})/)[1], null); } { "total_rows": 6, "rows": [ {"id":"5","key":"gif","value":null}, {"id":"6","key":"gif","value":null}, {"id":"1","key":"jpg","value":null}, {"id":"2","key":"jpg","value":null}, {"id":"3","key":"png","value":null}, {"id":"4","key":"png","value":null} ] } will leinweber — bitfission.com — merge.fm — @leinweber
function(doc) {
emit(doc.name.match(/w+.(w{3})/)[1], null); } ?key="jpg" { "total_rows": 2, "rows": [ {"id":"1","key":"jpg","value":null}, {"id":"2","key":"jpg","value":null}, ] } will leinweber — bitfission.com — merge.fm — @leinweber
//reduce //map function(doc) {
function(keys,values,rereduce) { emit("size",doc.info.size); return sum(values); } } id key value 1 "size" 12345 { 2 "size" 32091 "rows": [ reduced 3 "size" 1253 {"key":"size","value":238208} 238208 4 "size" 92834 ] 5 "size" 49287 } 6 "size" 50398 will leinweber — bitfission.com — merge.fm — @leinweber
//reduce //map function(doc) {
function(keys,values,rereduce) { emit(doc.user, 1); return sum(values); } } id key value reduced { 1 "bob" 1 "rows": [ 2 "bob" 1 2 {"key":"bob","value":2}, 3 "john" 1 {"key":"john","value":3}, 4 "john" 1 3 {"key":"zztop","value":1} 5 "john" 1 ] 6 "zztop" 1 1 } will leinweber — bitfission.com — merge.fm — @leinweber
last example: complex keys
will leinweber — bitfission.com — merge.fm — @leinweber
{"_id":1,"name":"fish.jpg","user":"bob","camera":"nikon",
"info":{"width":100,"height":200,"size":12345},"tags":["tuna","shark"]} {"_id":2,"name":"trees.jpg","user":"john","camera":"canon", "info":{"width":30,"height":250,"size":32091},"tags":["oak"]} {"_id":3,"name":"snow.png","user":"john","camera":"canon", "info":{"width":64,"height":64,"size":1253},"tags":["tahoe","powder"]} {"_id":4,"name":"hawaii.png","user":"john","camera":"nikon", "info":{"width":128,"height":64,"size":92834},"tags":["maui","tuna"]} {"_id":5,"name":"hawaii.gif","user":"bob","camera":"canon", "info":{"width":320,"height":128,"size":49287},"tags":["maui"]} {"_id":6,"name":"island.gif","user":"zztop","camera":"nikon", "info":{"width":640,"height":480,"size":50398},"tags":["maui"]} will leinweber — bitfission.com — merge.fm — @leinweber
//map
//reduce function(doc) { function(keys,values,rereduce){ emit([doc.user,doc.camera],1); return sum(values); } } id key value reduced { "rows": [ 5 ["bob","canon"] 1 1 {"key":["bob","canon"],"value":1}, 1 ["bob","nikon"] 1 1 {"key":["bob","nikon"],"value":1}, 2 ["john","canon"] 1 {"key":["john","canon"],"value":2}, 2 3 ["john","canon"] 1 {"key":["john","nikon"],"value":1}, 4 ["john","nikon"] 1 1 {"key":["zztop","nikon"],"value":1} ] 6 ["zztop","nikon"] 1 1 } will leinweber — bitfission.com — merge.fm — @leinweber
//map
//reduce function(doc) { function(keys,values,rereduce){ emit([doc.user,doc.camera],1); return sum(values); } } ?startkey=[“bob”]&endkey=[“bob”,{}] { "rows": [ {"key":["bob","canon"],"value":1}, {"key":["bob","nikon"],"value":1}, ] } will leinweber — bitfission.com — merge.fm — @leinweber
views are saved b+
trees will leinweber — bitfission.com — merge.fm — @leinweber
updated when accessed
will leinweber — bitfission.com — merge.fm — @leinweber
updated incrementally
will leinweber — bitfission.com — merge.fm — @leinweber
couchrest
will leinweber — bitfission.com — merge.fm — @leinweber
will leinweber —
bitfission.com — merge.fm — @leinweber
couchrest core
will leinweber — bitfission.com — merge.fm — @leinweber
DB = CouchRest.database!("temps") DB.save_doc
"_id" => "room1", "temps" => [34] #=> {"rev"=>"1-3b4f6c5218621d8876", "id"=>"room1", "ok"=>true} room = DB.get "room1" #=> {"temps"=>[34], "_rev"=>"1-3b4f6c5218621", "_id"=>"room1"} room["temps"] << 35 << 25 << 33 << 25 room.save #=> {"temps"=>[34,35,25,33,25],"_rev"=>"2-1d15c4a8a","_id"=>"room1"} will leinweber — bitfission.com — merge.fm — @leinweber
DB.view("temps/temp", :key=>25) #=> {"total_rows"=>5,
"rows"=>[ {"id"=>"room1", "value"=>{...}, "key"=>25} ]} will leinweber — bitfission.com — merge.fm — @leinweber
Extended Document
will leinweber — bitfission.com — merge.fm — @leinweber
class User <
CouchRest::ExtendedDocument property :name property :email property :posts, :default => [], :accessible => true timestamps! view_by :name view_by :post_ids, :map => %Q("function(doc) { if (doc['couchrest-type']=='User' && doc.post_ids){...) validates_with_method :name, :valid_name? validates_presence_of :email before_save :update_posts end will leinweber — bitfission.com — merge.fm — @leinweber
get couchdb
will leinweber — bitfission.com — merge.fm — @leinweber
homebrew couchdbx build will
leinweber — bitfission.com — merge.fm — @leinweber
links
will leinweber — bitfission.com — merge.fm — @leinweber
couchdb.apache.org books.couchdb.org github.com/couchrest bit.ly/jscouchdb
will leinweber — bitfission.com — merge.fm — @leinweber
thanks
will leinweber — bitfission.com — merge.fm — @leinweber
will leinweber —
bitfission.com — merge.fm — @leinweber
Editor's Notes
Advertisement