Presentation is loading. Please wait.

Presentation is loading. Please wait.

Is Apache CouchDB for you?

Similar presentations


Presentation on theme: "Is Apache CouchDB for you?"— Presentation transcript:

1 Is Apache CouchDB for you?
Sumedha Rubasinghe

2 During this 45 mins.. What is Apache CouchDB?
Paradigm for modeling data Demonstration Features

3 What CouchDB is NOT.. Relational Database SQL Tabular storage of data
Replacement for relational databases

4 Different paradigm to model data
Real world application – based on data in a document Relational model – maps data into tables, columns How about storing the document as it is !!!

5 What is CouchDB then? Document based database server
Key-value type of storage Schema free documents stored in JSON format versioning REST API Views Open source

6 JSON ? Java Script Object Notation
lightweight data storage format based on a subset of JavaScipt syntax eg: { "Subject": "ASF turns 10", "Author": "ajith", "PostedDate": " ", "Tags": [ "Apache Software Foundation", "Open source" ], "Body": "Recently Apache Software Foundation became 10 years old." }

7 Getting started - Installation
Documentation n Unix-like systems Mac OS X Windows Latest source distribution (4th Dec 2009) 0.10.1

8 Accessing DB engine - REST
REST API curl (unix like OS) cURL (windows) GET/PUT/POST/DELETE

9 Accessing DB engine - Futon
Futon – Web administration console

10 Creating a database Using REST API Using Futon

11 Creating a document Futon REST API

12 Views What is a view? View in CouchDB context
A "show" that directly renders a document using JavaScript MapReduce Two types Permanent view Indexed JSON for the view is stored as a design document Temporary view Sent via a HTTP POST Computed on the fly Creating a view using Futon

13 Programming with CouchDB
Clients available for many languages C, C#, Erlang, Java, JavaScript, Perl, PHP, Python,Ruby & many more..

14 Sample Java Client (CouchDB4J)
connection

15 Sample Java Client (CouchDB4J)
Accessing views

16 CouchApp Develop CouchDB applications in a convenient directory structure Separate folder for css,js,images,etc... To deploy – couchapp push Change & deploy – couchapp push

17 Interesting features Replication Versioning Validation
functions/macros

18 Important configuration files
Linux environment Start up script /usr/local/etc/init.d/couchdb start | status | stop Configurations (ports,users) /usr/local/etc/couchdb/local.ini

19 Samples on the web http://jchrisa.net/cal/_design/cal/index .html

20 References

21 Thank you


Download ppt "Is Apache CouchDB for you?"

Similar presentations


Ads by Google