1) What is CouchDB?
CouchDB is document database server accessible through a RESTful JSON API. It is distributed, robust, incremental replication with bi-direction. It is schema-free with flat address space.
2) In which language CouchDB is written?
CouchDB is written in Erlang. It is a concurrent, functional programming language maily focus on fault tolerance.
3) In which language CouchDB's early work was started?
CouchDB early work was started in C++. But later it was replaced by Erlang OTP platform.
4) How CouchDB is different from other SQL databases?
CouchDB is not a relational database. Some people think that it is a replacement of relational database but it is totally different from SQL databases. It is fast, efficient and fault tolerant.
5) Is CouchDB used in Software industry?
CouchDB is very popular now a day and there are many companies using CouchDB.
6) What is the difference between CouchDB and MongoDB?
Criteria | CouchDB | MongoDB |
---|---|---|
Interface | REST/HTTP | TCP/IP Custom Protocol |
Object Storage | Record is stored in documents in database. | Record is stored in collections in database. |
Replication | It follows Master-Master replication. | It follows Master-Slave replication. |
7) What is the similarity between MongoDB and CouchDB?
Similarity between MongoDB and CouchDB:
- MongoDB and CouchDB both are document oriented database.
- MongoDB and CouchDB both are the best example of open-source NoSQL database.
8) What are the main features of CouchDB?
- JSON Documents: CouchDB stores data in JSON document.
- RESTful Interface: CouchDB does all tasks like replication, data insertion etc. via HTTP.
- N-Master Replication: CouchDB facilitates you to make use of an unlimited amount of 'masters', making for some very interesting replication topologies.
- Built for Offline: CouchDB can replicate to devices (like Android phones) that can go offline and handle data sync for you when the device is back online.
- Replication Filters: CouchDB facilitates you to filter precisely the data you wish to replicate to different nodes.
9) Why Does CouchDB Not Use Mnesia?
There are many reasons behind CouchDB not using Mnesia:
- It provides a storage limitation of 2 gig per file.
- It requires a validation and fixup cycle after a crash or power failure, so even if the size limitation is lifted, the fixup time on large files is prohibitive.
- Mnesia has some useful features but features of Mnesia aren't really useful for CouchDB.
- Mnesia is not a general-purpose, large scale database. It works best as a configuration type database.
10) How would you use transactions with CouchDB?
CouchDB uses an "Optimistic concurrency" model. In this model, if you send a document version along with your update, CouchDB rejects the change if the current document version doesn't match to your sent update.
So you have to re-frame many normal transaction based scenarios for CouchDB. It's helpful to approach problems from a higher level, rather than attempting to mold Couch to a SQL based world.
11) As CouchDB is written in Erlang and Erlang is known as slow to adopt Unicode. So, if it create a problem to CouchDB?
CouchDB uses Erlang binary internally. So, data come to CouchDB is always UTF-8 encoded.
12) What is the usage of CouchDB?
CouchDB facilitates developers to write a client side application which interacts directly to the Couch without the need of server-side middle layer. It reduces the time of development and handling replication. Its database is stored locally so the application can run almost no latency. The main objective of CouchDB is to run on the internet applications and the connected devices through which we access the internet.
13) What you know by CouchdbKit?
CouchdbKit provides a framework for your Python application to access and manage Python applications.
14) Can Views update documents or databases?
No. Views are always read only for databases and their documents.
15) What platforms are supported in CouchDB?
Most POSIX systems are supported like GNU/Linux and OS X. Windows is not officially supported but it should work.
16) What is the use of sequences, How do you do sequences?
Sequences are often used to ensure unique identifiers for each row in a database table. Sequences are hard to realize with replication. CouchDB generates unique ids from its own and you can specify your own as well, so you don't really need a sequence here. If you use a sequence for something else, you might find a way to express in CouchDB in another way.
17) How can you do replication?
Here $source_database and $target_database can be the names of local database or full URIs of remote databases. Both databases need to be created before they can be replicated from or to.
18) Is it possible to communicate to CouchDB without going through HTTP/ API?
CouchDB's data model and internal API map the REST/HTTP model in a very simple way that any other API would basically inherit some features of HTTP. However, there is a plan to refractor CouchDB's internals so as to provide a documented Erlang API.
0 comments:
Post a Comment