zhhealthcare/openemr — comment on commit a6eba8773aec7e1e51e67385011e2cf2b90739c2
File:  line 0
By zhhealthcare:

I)
Two things I wonder about off the top of my head are:
1) Does it support renaming of documents
Yes, we can rename the documents now.

2) If only CouchDB is used, what happens when make patient reports (and ImageMagick is used to convert some of the files)
It is implemented but not checked.

II)
Also, just a quick question just for my education. What are the advantages of using CouchDB over mysql to do this? (just curious why your group decided to go with couchdb rather than simply placing them in the already existent mysql database)

We tried to store the document in MySQL and faced with the following problems:

1) Whenever we tried for a restore from the backup, it fails.
2) Its heavily increasing the size of the DB and the backup time. This will be a very big problem for the installations with more than one DB.
3) We think that in the case of an emergency restore, the basic data will be more important than all the documents. If the documents are stored in the mysql, the database size may be grown to GBs rapidly which will be a problem in the case of emergency recovery.

Advantages:

1) Couch DB has a replication feature, so mysql replication and CouchDB replication can be implemented simultaneously which give almost consistent and upto date data everytime (We cannot find a file replication program which suits our requirement).
2) Couch DB is written to be fault tolerant.
3) Also its use a version controller system for storing the documents.
4) Couch DB can be scalable to handle any volume of data.
5) Its document storage structure can be used for some special requirement, for example: a robust email handling feature for openemr (it will be much easier than implementing using mysql). As far as we are concerned, its replication feature is the most attractive.
6) We are studying its advanced feature and we are not yet experts on this.