SlideShare uma empresa Scribd logo
1 de 34
Baixar para ler offline
CouchDB
w ruby'm, na przykładach
Kim jestem?




20.04.2010     Stanisław Wasiutyński   2
Plan prezentacji

             CouchDB                                  Ruby
 ●   Nierelacyjna baza danych           ●   Couchrest
 ●   RESTful JSON API                   ●   Couch_foo
 ●   Widoki (MapReduce)                 ●   Couch_potato
 ●   Replikacje                         ●   Reverse proxy



              teoria                               praktyka


20.04.2010                 Stanisław Wasiutyński              3
20.04.2010   Stanisław Wasiutyński                                                       4

                                     Źródło: http://blog.nahurst.com/visual-guide-to-nosql-systems
tu jestem




20.04.2010   Stanisław Wasiutyński                                                       5

                                     Źródło: http://blog.nahurst.com/visual-guide-to-nosql-systems
Document-Oriented
 ●   Wszystkie dane są przechowywane w formie dokumentów
     o dowolnym rozmiarze.
 ●   Każdy dokument ma unikalną nazwę, oraz posiada
     dowolną liczbę pól o unikalnej nazwie.
 ●   Każdemu polu (kluczowi) odpowiada wartość dowolnego
     typu (np. String, Integer, Array, Hash).
 ●   Na dokumentach wykonywane są operacje CRUD (Create,
     Read, Update, Delete) tylko na całym dokumencie, nigdy
     na jego fragmencie.



20.04.2010               Stanisław Wasiutyński             6
RESTful JSON API
             {
                 "_id": "fb288af72d22797f5cf68a73a7a5cb89",
                 "_rev": "12-8f531b2a273d35ecd4af58e930525e8c",
                 "couchrest-type": "Line",
                 "no": 117,
                 "begin_date": "2009/10/03",
                 "timetables": [
                   {
                     "data": {"pon-pt": [...], "sob": [...]},
                     "stop_id": "acf81f2770a21481bf0e784b7b506d38"
                   },
                   ...
                 ],
                 "updated_at": "2010/03/08 21:08:50 +0000",
                 "created_at": "2010/01/22 21:50:19 +0000"
             }



20.04.2010                          Stanisław Wasiutyński            7
RESTful JSON API


                Stwórz:                 POST /db/<id>

                Czytaj:                   GET /db/<id>

             Aktualizuj:                  PUT /db/<id>

                 Usuń:              DELETE /db/<id>




20.04.2010                 Stanisław Wasiutyński         8
20.04.2010   Stanisław Wasiutyński   9
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               10
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               11
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               12
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               13
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               14
RESTful JSON API

[~] ➔ curl http://localhost:5984/
[info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200
{"couchdb":"Welcome","version":"0.11.0"}
[~] ➔ curl -X PUT http://localhost:5984/krug
[info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201
{"ok":true}
[~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}'
[info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"Temat": "Witaj okrutny świecie!"}'
[info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409
{"error":"conflict","reason":"Document update conflict."}
[~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be 
> -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}'
{"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"}
[info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201
[~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be
[info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200
{"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4",
"Temat":"Witaj okrutny u015bwiecie!"}
[~] ➔

    20.04.2010                           Stanisław Wasiutyński                               15
Coś więcej niż wymyślny
      serwer plików.




20.04.2010      Stanisław Wasiutyński                                          16

                                        http://www.flickr.com/photos/santos/1704875109/
Widoki
 ●   Są przechowywane jako dokumenty,
 ●   definiują dowolne funkcje map i reduce,
 ●   służą do budowy wydajnych indeksów,
 ●   pozwalają na niezależne przetwarzanie pojedynczych
     dokumentów i zwrócenie ich w pożądanym formacie,
 ●   generowane równolegle, inkrementalnie i na żądanie,
 ●   brak dynamicznych zapytań („close to the metal”),
 ●   rozbudowane API.



20.04.2010                 Stanisław Wasiutyński           17
Map Reduce




GET /_design/comments/_view/cenzor?limit=11&reduce=false
GET /_design/comments/_view/cenzor?limit=11&reduce=false&
    startkey=[<id>, <rok>, <miesiąc>, <dzień>]&
    endkey=[<id>, <rok>, <miesiąc>, <dzień>+3]

GET /_design/comments/_view/cenzor?limit=11&group=true&group_level=3
GET /_design/comments/_view/cenzor?group=true&group_level=1&key=[<id>]



20.04.2010                       Stanisław Wasiutyński                   18
Replikacje
 ●    Dwustronne, inkrementalne,
 ●    replikacja podzbioru (przez filtry),
 ●    rozwiązywanie konfliktów.

                                                      korzyści
 ●    Łatwe skalowanie wszerz,
 ●    praca off-line.


     curl -X POST http://localhost:5984/_replicate -d
     {"source": "http://couch.db/remote", "target": "local"}



20.04.2010                    Stanisław Wasiutyński              19
Replikacje




20.04.2010    Stanisław Wasiutyński                                                    20

                                      http://www.slideshare.net/mlmilleratmit/20100310-miller-sts
Ruby




20.04.2010   Stanisław Wasiutyński   21
Couchrest




             Couchrest


20.04.2010      Stanisław Wasiutyński   22
20.04.2010   Stanisław Wasiutyński   23
Couch_foo


20.04.2010      Stanisław Wasiutyński   24
20.04.2010   Stanisław Wasiutyński   25
Couch_potato


20.04.2010       Stanisław Wasiutyński   26
20.04.2010   Stanisław Wasiutyński   27
em_proxy


20.04.2010     Stanisław Wasiutyński   28
20.04.2010   Stanisław Wasiutyński   29
O czym nie mówiłem?
 ●   Couchdb-Lucene – pełno-tekstowa wyszukiwarka
     dokumentów CouchDB,
 ●   Couchdb-Lounge – proxy framework do partycjonowania
     CouchDB,
 ●   CouchApps - samowystarczalne aplikacje CouchDB,
 ●   bezpieczeństwo,
 ●   binarne załączniki,
 ●   walidacja dokumentów,
 ●   BrowserCouch – CouchDB w przeglądarce.


20.04.2010                 Stanisław Wasiutyński           30
Więcej o CouchDB na:
 ●   http://couchdb.apache.org/
 ●   http://www.couch.io/
 ●   http://wiki.apache.org/couchdb/
 ●   http://books.couchdb.org/relax/


     Oraz:
 ●   http://stackoverflow.com/questions/tagged/couchdb
 ●   http://www.reddit.com/search?q=couchdb




20.04.2010                     Stanisław Wasiutyński     31
Dziękuję za uwagę.




20.04.2010        Stanisław Wasiutyński   32
Fork me:
             github.com/Stanley




20.04.2010     Stanisław Wasiutyński   33
Pytania?




20.04.2010   Stanisław Wasiutyński   34

Mais conteúdo relacionado

Mais procurados

Redis - Usability and Use Cases
Redis - Usability and Use CasesRedis - Usability and Use Cases
Redis - Usability and Use CasesFabrizio Farinacci
 
DEF CON 23 - amit ashbel and maty siman - game of hacks
DEF CON 23 - amit ashbel and maty siman - game of hacks DEF CON 23 - amit ashbel and maty siman - game of hacks
DEF CON 23 - amit ashbel and maty siman - game of hacks Felipe Prado
 
Back to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationBack to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationMongoDB
 
Mac OS X Lion で作る WordPress local 環境
Mac OS X Lion で作る WordPress local 環境Mac OS X Lion で作る WordPress local 環境
Mac OS X Lion で作る WordPress local 環境Yuriko IKEDA
 
Back to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsBack to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsJoe Drumgoole
 
Back to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLBack to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLJoe Drumgoole
 
MongoDB全機能解説2
MongoDB全機能解説2MongoDB全機能解説2
MongoDB全機能解説2Takahiro Inoue
 
San Francisco Java User Group
San Francisco Java User GroupSan Francisco Java User Group
San Francisco Java User Groupkchodorow
 
MongoDBで作るソーシャルデータ新解析基盤
MongoDBで作るソーシャルデータ新解析基盤MongoDBで作るソーシャルデータ新解析基盤
MongoDBで作るソーシャルデータ新解析基盤Takahiro Inoue
 
Redis for the Everyday Developer
Redis for the Everyday DeveloperRedis for the Everyday Developer
Redis for the Everyday DeveloperRoss Tuck
 
PHP Identity and Data Security
PHP Identity and Data SecurityPHP Identity and Data Security
PHP Identity and Data SecurityJonathan LeBlanc
 
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v Arian Gutierrez
 
Kicking ass with redis
Kicking ass with redisKicking ass with redis
Kicking ass with redisDvir Volk
 
Paris js extensions
Paris js extensionsParis js extensions
Paris js extensionserwanl
 
NoSQL & MongoDB
NoSQL & MongoDBNoSQL & MongoDB
NoSQL & MongoDBShuai Liu
 
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化Taro Matsuzawa
 
MongoDB Performance Debugging
MongoDB Performance DebuggingMongoDB Performance Debugging
MongoDB Performance DebuggingMongoDB
 
RESTing with the new Yandex.Disk API, Clemens Аuer
RESTing with the new Yandex.Disk API, Clemens АuerRESTing with the new Yandex.Disk API, Clemens Аuer
RESTing with the new Yandex.Disk API, Clemens АuerYandex
 

Mais procurados (20)

Redis - Usability and Use Cases
Redis - Usability and Use CasesRedis - Usability and Use Cases
Redis - Usability and Use Cases
 
DEF CON 23 - amit ashbel and maty siman - game of hacks
DEF CON 23 - amit ashbel and maty siman - game of hacks DEF CON 23 - amit ashbel and maty siman - game of hacks
DEF CON 23 - amit ashbel and maty siman - game of hacks
 
Back to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationBack to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB Application
 
Mac OS X Lion で作る WordPress local 環境
Mac OS X Lion で作る WordPress local 環境Mac OS X Lion で作る WordPress local 環境
Mac OS X Lion で作る WordPress local 環境
 
Mongo db presentation
Mongo db presentationMongo db presentation
Mongo db presentation
 
Back to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsBack to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in Documents
 
Back to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLBack to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQL
 
MongoDB全機能解説2
MongoDB全機能解説2MongoDB全機能解説2
MongoDB全機能解説2
 
San Francisco Java User Group
San Francisco Java User GroupSan Francisco Java User Group
San Francisco Java User Group
 
MongoDBで作るソーシャルデータ新解析基盤
MongoDBで作るソーシャルデータ新解析基盤MongoDBで作るソーシャルデータ新解析基盤
MongoDBで作るソーシャルデータ新解析基盤
 
Redis for the Everyday Developer
Redis for the Everyday DeveloperRedis for the Everyday Developer
Redis for the Everyday Developer
 
PHP Identity and Data Security
PHP Identity and Data SecurityPHP Identity and Data Security
PHP Identity and Data Security
 
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v
Tipo virus espia con esto aprenderan a espiar a personas etc jeropas de mrd :v
 
Kicking ass with redis
Kicking ass with redisKicking ass with redis
Kicking ass with redis
 
Paris js extensions
Paris js extensionsParis js extensions
Paris js extensions
 
NoSQL & MongoDB
NoSQL & MongoDBNoSQL & MongoDB
NoSQL & MongoDB
 
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化
スマートフォン勉強会@関東 #11 LT 5分で語る SQLite暗号化
 
MongoDB Performance Debugging
MongoDB Performance DebuggingMongoDB Performance Debugging
MongoDB Performance Debugging
 
Trimming The Cruft
Trimming The CruftTrimming The Cruft
Trimming The Cruft
 
RESTing with the new Yandex.Disk API, Clemens Аuer
RESTing with the new Yandex.Disk API, Clemens АuerRESTing with the new Yandex.Disk API, Clemens Аuer
RESTing with the new Yandex.Disk API, Clemens Аuer
 

Destaque

Art History Final
Art History FinalArt History Final
Art History Finallcooney1
 
Brandraising Jewishly
Brandraising JewishlyBrandraising Jewishly
Brandraising JewishlySarah Durham
 
Slide Show Power Point For Lis
Slide Show Power Point For LisSlide Show Power Point For Lis
Slide Show Power Point For Lisguest884572
 
Social Media &amp; Your Business
Social Media &amp; Your BusinessSocial Media &amp; Your Business
Social Media &amp; Your Businessduncanro
 
Mini Kajian Tindakan
Mini Kajian TindakanMini Kajian Tindakan
Mini Kajian Tindakanasak
 
Minicurso Objective-C LinguÁgil 2011 (parte2)
Minicurso Objective-C LinguÁgil 2011 (parte2)Minicurso Objective-C LinguÁgil 2011 (parte2)
Minicurso Objective-C LinguÁgil 2011 (parte2)Cleverson Sacramento
 
Unitats electriques
Unitats electriquesUnitats electriques
Unitats electriquesAvel·lí
 
Тенденции рынков энергоэффективных решений для зданий
Тенденции рынков энергоэффективных решений для зданийТенденции рынков энергоэффективных решений для зданий
Тенденции рынков энергоэффективных решений для зданийAgency of Industrial Marketing
 
Windows Presentation Foundation
Windows Presentation FoundationWindows Presentation Foundation
Windows Presentation Foundationcieszak
 
Presentazione standard1
Presentazione standard1Presentazione standard1
Presentazione standard1VivianaaF
 
Birthplace of country music
Birthplace of country musicBirthplace of country music
Birthplace of country musicMdbrandon32
 
Convergence India 2013 Multi-network Forum - Verimatrix
Convergence India 2013 Multi-network Forum - VerimatrixConvergence India 2013 Multi-network Forum - Verimatrix
Convergence India 2013 Multi-network Forum - VerimatrixVerimatrix
 
Мониторинг рынка электроводонагревателей
Мониторинг рынка электроводонагревателейМониторинг рынка электроводонагревателей
Мониторинг рынка электроводонагревателейAgency of Industrial Marketing
 
2012 – what the bleep is it all about
2012 – what the bleep is it all about2012 – what the bleep is it all about
2012 – what the bleep is it all aboutGlen Tucker
 
Emergencias medicas
Emergencias medicasEmergencias medicas
Emergencias medicasJorge
 

Destaque (20)

Art History Final
Art History FinalArt History Final
Art History Final
 
Brandraising Jewishly
Brandraising JewishlyBrandraising Jewishly
Brandraising Jewishly
 
Slide Show Power Point For Lis
Slide Show Power Point For LisSlide Show Power Point For Lis
Slide Show Power Point For Lis
 
Se 2012-06 en
Se 2012-06 enSe 2012-06 en
Se 2012-06 en
 
Social Media &amp; Your Business
Social Media &amp; Your BusinessSocial Media &amp; Your Business
Social Media &amp; Your Business
 
Mini Kajian Tindakan
Mini Kajian TindakanMini Kajian Tindakan
Mini Kajian Tindakan
 
Minicurso Objective-C LinguÁgil 2011 (parte2)
Minicurso Objective-C LinguÁgil 2011 (parte2)Minicurso Objective-C LinguÁgil 2011 (parte2)
Minicurso Objective-C LinguÁgil 2011 (parte2)
 
Unitats electriques
Unitats electriquesUnitats electriques
Unitats electriques
 
Ставлю на знання
Ставлю на знанняСтавлю на знання
Ставлю на знання
 
Verb To Be
Verb To BeVerb To Be
Verb To Be
 
Тенденции рынков энергоэффективных решений для зданий
Тенденции рынков энергоэффективных решений для зданийТенденции рынков энергоэффективных решений для зданий
Тенденции рынков энергоэффективных решений для зданий
 
Windows Presentation Foundation
Windows Presentation FoundationWindows Presentation Foundation
Windows Presentation Foundation
 
Presentazione standard1
Presentazione standard1Presentazione standard1
Presentazione standard1
 
Ch 5 Motivation
Ch 5 MotivationCh 5 Motivation
Ch 5 Motivation
 
Birthplace of country music
Birthplace of country musicBirthplace of country music
Birthplace of country music
 
How2mk freind with any1 zam naim
How2mk freind with any1 zam naimHow2mk freind with any1 zam naim
How2mk freind with any1 zam naim
 
Convergence India 2013 Multi-network Forum - Verimatrix
Convergence India 2013 Multi-network Forum - VerimatrixConvergence India 2013 Multi-network Forum - Verimatrix
Convergence India 2013 Multi-network Forum - Verimatrix
 
Мониторинг рынка электроводонагревателей
Мониторинг рынка электроводонагревателейМониторинг рынка электроводонагревателей
Мониторинг рынка электроводонагревателей
 
2012 – what the bleep is it all about
2012 – what the bleep is it all about2012 – what the bleep is it all about
2012 – what the bleep is it all about
 
Emergencias medicas
Emergencias medicasEmergencias medicas
Emergencias medicas
 

Semelhante a CouchDB and Ruby Integration

Apache CouchDB talk at Ontario GNU Linux Fest
Apache CouchDB talk at Ontario GNU Linux FestApache CouchDB talk at Ontario GNU Linux Fest
Apache CouchDB talk at Ontario GNU Linux FestMyles Braithwaite
 
CouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourCouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourPeter Friese
 
OSCON 2011 CouchApps
OSCON 2011 CouchAppsOSCON 2011 CouchApps
OSCON 2011 CouchAppsBradley Holt
 
Top 10 F5 iRules to migrate to a modern load balancing platform
Top 10 F5 iRules to migrate to a modern load balancing platformTop 10 F5 iRules to migrate to a modern load balancing platform
Top 10 F5 iRules to migrate to a modern load balancing platformAvi Networks
 
Couchdb: No SQL? No driver? No problem
Couchdb: No SQL? No driver? No problemCouchdb: No SQL? No driver? No problem
Couchdb: No SQL? No driver? No problemdelagoya
 
Anwendungsfaelle für Elasticsearch
Anwendungsfaelle für ElasticsearchAnwendungsfaelle für Elasticsearch
Anwendungsfaelle für ElasticsearchFlorian Hopf
 
Finch.io - Purely Functional REST API with Finagle
Finch.io - Purely Functional REST API with FinagleFinch.io - Purely Functional REST API with Finagle
Finch.io - Purely Functional REST API with FinagleVladimir Kostyukov
 
Intravert Server side processing for Cassandra
Intravert Server side processing for CassandraIntravert Server side processing for Cassandra
Intravert Server side processing for CassandraEdward Capriolo
 
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"DataStax Academy
 
OSCON 2011 Learning CouchDB
OSCON 2011 Learning CouchDBOSCON 2011 Learning CouchDB
OSCON 2011 Learning CouchDBBradley Holt
 
REST with Eve and Python
REST with Eve and PythonREST with Eve and Python
REST with Eve and PythonPiXeL16
 
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCar
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCarDo Zero ao Node.js - Especialização em Engenharia de Software - UFSCar
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCarPablo Souza
 
Node.js 與 google cloud storage
Node.js 與 google cloud storageNode.js 與 google cloud storage
Node.js 與 google cloud storageonlinemad
 
Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB
 Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB
Conceptos básicos. Seminario web 2: Su primera aplicación MongoDBMongoDB
 
Developing RESTful WebServices using Jersey
Developing RESTful WebServices using JerseyDeveloping RESTful WebServices using Jersey
Developing RESTful WebServices using Jerseyb_kathir
 
Forbes MongoNYC 2011
Forbes MongoNYC 2011Forbes MongoNYC 2011
Forbes MongoNYC 2011djdunlop
 
Full stack development with node and NoSQL - All Things Open - October 2017
Full stack development with node and NoSQL - All Things Open - October 2017Full stack development with node and NoSQL - All Things Open - October 2017
Full stack development with node and NoSQL - All Things Open - October 2017Matthew Groves
 
Full Stack Development with Node.js and NoSQL
Full Stack Development with Node.js and NoSQLFull Stack Development with Node.js and NoSQL
Full Stack Development with Node.js and NoSQLAll Things Open
 

Semelhante a CouchDB and Ruby Integration (20)

Apache CouchDB talk at Ontario GNU Linux Fest
Apache CouchDB talk at Ontario GNU Linux FestApache CouchDB talk at Ontario GNU Linux Fest
Apache CouchDB talk at Ontario GNU Linux Fest
 
CouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourCouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 Hour
 
OSCON 2011 CouchApps
OSCON 2011 CouchAppsOSCON 2011 CouchApps
OSCON 2011 CouchApps
 
Top 10 F5 iRules to migrate to a modern load balancing platform
Top 10 F5 iRules to migrate to a modern load balancing platformTop 10 F5 iRules to migrate to a modern load balancing platform
Top 10 F5 iRules to migrate to a modern load balancing platform
 
Couchdb: No SQL? No driver? No problem
Couchdb: No SQL? No driver? No problemCouchdb: No SQL? No driver? No problem
Couchdb: No SQL? No driver? No problem
 
Anwendungsfaelle für Elasticsearch
Anwendungsfaelle für ElasticsearchAnwendungsfaelle für Elasticsearch
Anwendungsfaelle für Elasticsearch
 
Socket.IO
Socket.IOSocket.IO
Socket.IO
 
Finch.io - Purely Functional REST API with Finagle
Finch.io - Purely Functional REST API with FinagleFinch.io - Purely Functional REST API with Finagle
Finch.io - Purely Functional REST API with Finagle
 
Pyrax talk
Pyrax talkPyrax talk
Pyrax talk
 
Intravert Server side processing for Cassandra
Intravert Server side processing for CassandraIntravert Server side processing for Cassandra
Intravert Server side processing for Cassandra
 
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
NYC* 2013 - "Advanced Data Processing: Beyond Queries and Slices"
 
OSCON 2011 Learning CouchDB
OSCON 2011 Learning CouchDBOSCON 2011 Learning CouchDB
OSCON 2011 Learning CouchDB
 
REST with Eve and Python
REST with Eve and PythonREST with Eve and Python
REST with Eve and Python
 
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCar
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCarDo Zero ao Node.js - Especialização em Engenharia de Software - UFSCar
Do Zero ao Node.js - Especialização em Engenharia de Software - UFSCar
 
Node.js 與 google cloud storage
Node.js 與 google cloud storageNode.js 與 google cloud storage
Node.js 與 google cloud storage
 
Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB
 Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB
Conceptos básicos. Seminario web 2: Su primera aplicación MongoDB
 
Developing RESTful WebServices using Jersey
Developing RESTful WebServices using JerseyDeveloping RESTful WebServices using Jersey
Developing RESTful WebServices using Jersey
 
Forbes MongoNYC 2011
Forbes MongoNYC 2011Forbes MongoNYC 2011
Forbes MongoNYC 2011
 
Full stack development with node and NoSQL - All Things Open - October 2017
Full stack development with node and NoSQL - All Things Open - October 2017Full stack development with node and NoSQL - All Things Open - October 2017
Full stack development with node and NoSQL - All Things Open - October 2017
 
Full Stack Development with Node.js and NoSQL
Full Stack Development with Node.js and NoSQLFull Stack Development with Node.js and NoSQL
Full Stack Development with Node.js and NoSQL
 

Último

SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
What is Artificial Intelligence?????????
What is Artificial Intelligence?????????What is Artificial Intelligence?????????
What is Artificial Intelligence?????????blackmambaettijean
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESmohitsingh558521
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfMounikaPolabathina
 

Último (20)

SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
What is Artificial Intelligence?????????
What is Artificial Intelligence?????????What is Artificial Intelligence?????????
What is Artificial Intelligence?????????
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdf
 

CouchDB and Ruby Integration

  • 1. CouchDB w ruby'm, na przykładach
  • 2. Kim jestem? 20.04.2010 Stanisław Wasiutyński 2
  • 3. Plan prezentacji CouchDB Ruby ● Nierelacyjna baza danych ● Couchrest ● RESTful JSON API ● Couch_foo ● Widoki (MapReduce) ● Couch_potato ● Replikacje ● Reverse proxy teoria praktyka 20.04.2010 Stanisław Wasiutyński 3
  • 4. 20.04.2010 Stanisław Wasiutyński 4 Źródło: http://blog.nahurst.com/visual-guide-to-nosql-systems
  • 5. tu jestem 20.04.2010 Stanisław Wasiutyński 5 Źródło: http://blog.nahurst.com/visual-guide-to-nosql-systems
  • 6. Document-Oriented ● Wszystkie dane są przechowywane w formie dokumentów o dowolnym rozmiarze. ● Każdy dokument ma unikalną nazwę, oraz posiada dowolną liczbę pól o unikalnej nazwie. ● Każdemu polu (kluczowi) odpowiada wartość dowolnego typu (np. String, Integer, Array, Hash). ● Na dokumentach wykonywane są operacje CRUD (Create, Read, Update, Delete) tylko na całym dokumencie, nigdy na jego fragmencie. 20.04.2010 Stanisław Wasiutyński 6
  • 7. RESTful JSON API { "_id": "fb288af72d22797f5cf68a73a7a5cb89", "_rev": "12-8f531b2a273d35ecd4af58e930525e8c", "couchrest-type": "Line", "no": 117, "begin_date": "2009/10/03", "timetables": [ { "data": {"pon-pt": [...], "sob": [...]}, "stop_id": "acf81f2770a21481bf0e784b7b506d38" }, ... ], "updated_at": "2010/03/08 21:08:50 +0000", "created_at": "2010/01/22 21:50:19 +0000" } 20.04.2010 Stanisław Wasiutyński 7
  • 8. RESTful JSON API Stwórz: POST /db/<id> Czytaj: GET /db/<id> Aktualizuj: PUT /db/<id> Usuń: DELETE /db/<id> 20.04.2010 Stanisław Wasiutyński 8
  • 9. 20.04.2010 Stanisław Wasiutyński 9
  • 10. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 10
  • 11. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 11
  • 12. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 12
  • 13. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 13
  • 14. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 14
  • 15. RESTful JSON API [~] ➔ curl http://localhost:5984/ [info] [<0.95.0>] 127.0.0.1 - - 'GET' / 200 {"couchdb":"Welcome","version":"0.11.0"} [~] ➔ curl -X PUT http://localhost:5984/krug [info] [<0.124.0>] 127.0.0.1 - - 'PUT' /krug 201 {"ok":true} [~] ➔ curl -X POST http://localhost:5984/krug -d '{"Temat": "Witaj świecie!"}' [info] [<0.216.0>] 127.0.0.1 - - 'POST' /krug 201 {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a"} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"Temat": "Witaj okrutny świecie!"}' [info] [<0.668.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 409 {"error":"conflict","reason":"Document update conflict."} [~] ➔ curl -X PUT http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be > -d '{"_rev":"1-4777d27f9e980ed1ce8cf94c0bc1d27a", "Temat": "Witaj okrutny świecie!"}' {"ok":true,"id":"8cb7299cc68d35a2ca4a0c18070009be","rev":"2-e51a077b62b9bfbc8faac8aff60733b4"} [info] [<0.774.0>] 127.0.0.1 - - 'PUT' /krug/8cb7299cc68d35a2ca4a0c18070009be 201 [~] ➔ curl http://localhost:5984/krug/8cb7299cc68d35a2ca4a0c18070009be [info] [<0.1264.0>] 127.0.0.1 - - 'GET' /krug/8cb7299cc68d35a2ca4a0c18070009be 200 {"_id":"8cb7299cc68d35a2ca4a0c18070009be","_rev":"2-e51a077b62b9bfbc8faac8aff60733b4", "Temat":"Witaj okrutny u015bwiecie!"} [~] ➔ 20.04.2010 Stanisław Wasiutyński 15
  • 16. Coś więcej niż wymyślny serwer plików. 20.04.2010 Stanisław Wasiutyński 16 http://www.flickr.com/photos/santos/1704875109/
  • 17. Widoki ● Są przechowywane jako dokumenty, ● definiują dowolne funkcje map i reduce, ● służą do budowy wydajnych indeksów, ● pozwalają na niezależne przetwarzanie pojedynczych dokumentów i zwrócenie ich w pożądanym formacie, ● generowane równolegle, inkrementalnie i na żądanie, ● brak dynamicznych zapytań („close to the metal”), ● rozbudowane API. 20.04.2010 Stanisław Wasiutyński 17
  • 18. Map Reduce GET /_design/comments/_view/cenzor?limit=11&reduce=false GET /_design/comments/_view/cenzor?limit=11&reduce=false& startkey=[<id>, <rok>, <miesiąc>, <dzień>]& endkey=[<id>, <rok>, <miesiąc>, <dzień>+3] GET /_design/comments/_view/cenzor?limit=11&group=true&group_level=3 GET /_design/comments/_view/cenzor?group=true&group_level=1&key=[<id>] 20.04.2010 Stanisław Wasiutyński 18
  • 19. Replikacje ● Dwustronne, inkrementalne, ● replikacja podzbioru (przez filtry), ● rozwiązywanie konfliktów. korzyści ● Łatwe skalowanie wszerz, ● praca off-line. curl -X POST http://localhost:5984/_replicate -d {"source": "http://couch.db/remote", "target": "local"} 20.04.2010 Stanisław Wasiutyński 19
  • 20. Replikacje 20.04.2010 Stanisław Wasiutyński 20 http://www.slideshare.net/mlmilleratmit/20100310-miller-sts
  • 21. Ruby 20.04.2010 Stanisław Wasiutyński 21
  • 22. Couchrest Couchrest 20.04.2010 Stanisław Wasiutyński 22
  • 23. 20.04.2010 Stanisław Wasiutyński 23
  • 24. Couch_foo 20.04.2010 Stanisław Wasiutyński 24
  • 25. 20.04.2010 Stanisław Wasiutyński 25
  • 26. Couch_potato 20.04.2010 Stanisław Wasiutyński 26
  • 27. 20.04.2010 Stanisław Wasiutyński 27
  • 28. em_proxy 20.04.2010 Stanisław Wasiutyński 28
  • 29. 20.04.2010 Stanisław Wasiutyński 29
  • 30. O czym nie mówiłem? ● Couchdb-Lucene – pełno-tekstowa wyszukiwarka dokumentów CouchDB, ● Couchdb-Lounge – proxy framework do partycjonowania CouchDB, ● CouchApps - samowystarczalne aplikacje CouchDB, ● bezpieczeństwo, ● binarne załączniki, ● walidacja dokumentów, ● BrowserCouch – CouchDB w przeglądarce. 20.04.2010 Stanisław Wasiutyński 30
  • 31. Więcej o CouchDB na: ● http://couchdb.apache.org/ ● http://www.couch.io/ ● http://wiki.apache.org/couchdb/ ● http://books.couchdb.org/relax/ Oraz: ● http://stackoverflow.com/questions/tagged/couchdb ● http://www.reddit.com/search?q=couchdb 20.04.2010 Stanisław Wasiutyński 31
  • 32. Dziękuję za uwagę. 20.04.2010 Stanisław Wasiutyński 32
  • 33. Fork me: github.com/Stanley 20.04.2010 Stanisław Wasiutyński 33
  • 34. Pytania? 20.04.2010 Stanisław Wasiutyński 34