Updated Branches: refs/heads/docs 20cc4afa4 -> c9efdb1bd renamed doc to docs Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/c9efdb1b Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/c9efdb1b Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/c9efdb1b Branch: refs/heads/docs Commit: c9efdb1bd7058e338c50661921379a51b4a99b4c Parents: 8dd87e8 Author: Noah Slater Authored: Sat Sep 29 17:11:03 2012 +0100 Committer: Noah Slater Committed: Sat Sep 29 17:11:03 2012 +0100 ---------------------------------------------------------------------- configure.ac | 2 +- share/Makefile.am | 2 +- share/doc/Makefile.am | 53 + share/doc/demo.mk | 173 ++++ share/doc/images/epub-icon.png | Bin 0 -> 19185 bytes share/doc/images/futon-createdb.png | Bin 0 -> 76194 bytes share/doc/images/futon-editdoc.png | Bin 0 -> 64369 bytes share/doc/images/futon-editeddoc.png | Bin 0 -> 69595 bytes share/doc/images/futon-overview.png | Bin 0 -> 63039 bytes share/doc/images/futon-replform.png | Bin 0 -> 68068 bytes share/doc/make.bat | 190 ++++ share/doc/src/api-basics.rst | 459 +++++++++ share/doc/src/api/authn.rst | 41 + share/doc/src/api/configuration.rst | 297 ++++++ share/doc/src/api/database.rst | 1463 ++++++++++++++++++++++++++++ share/doc/src/api/dbmaint.rst | 15 + share/doc/src/api/design.rst | 1264 ++++++++++++++++++++++++ share/doc/src/api/documents.rst | 931 ++++++++++++++++++ share/doc/src/api/local.rst | 169 ++++ share/doc/src/api/misc.rst | 805 +++++++++++++++ share/doc/src/api/reference.rst | 28 + share/doc/src/changes.rst | 43 + share/doc/src/commonjs.rst | 56 ++ share/doc/src/conf.py | 33 + share/doc/src/config_reference.rst | 288 ++++++ share/doc/src/configuring.rst | 95 ++ share/doc/src/ddocs.rst | 19 + share/doc/src/errors.rst | 37 + share/doc/src/http-proxying.rst | 94 ++ share/doc/src/index.rst | 48 + share/doc/src/intro.rst | 309 ++++++ share/doc/src/json-structure.rst | 413 ++++++++ share/doc/src/os-daemons.rst | 50 + share/doc/src/range.rst | 72 ++ share/doc/src/release.rst | 47 + share/doc/src/replication.rst | 383 ++++++++ share/doc/src/ssl.rst | 109 ++ share/docs/Makefile.am | 53 - share/docs/demo.mk | 173 ---- share/docs/images/epub-icon.png | Bin 19185 -> 0 bytes share/docs/images/futon-createdb.png | Bin 76194 -> 0 bytes share/docs/images/futon-editdoc.png | Bin 64369 -> 0 bytes share/docs/images/futon-editeddoc.png | Bin 69595 -> 0 bytes share/docs/images/futon-overview.png | Bin 63039 -> 0 bytes share/docs/images/futon-replform.png | Bin 68068 -> 0 bytes share/docs/make.bat | 190 ---- share/docs/src/api-basics.rst | 459 --------- share/docs/src/api/authn.rst | 41 - share/docs/src/api/configuration.rst | 297 ------ share/docs/src/api/database.rst | 1463 ---------------------------- share/docs/src/api/dbmaint.rst | 15 - share/docs/src/api/design.rst | 1264 ------------------------ share/docs/src/api/documents.rst | 931 ------------------ share/docs/src/api/local.rst | 169 ---- share/docs/src/api/misc.rst | 805 --------------- share/docs/src/api/reference.rst | 28 - share/docs/src/changes.rst | 43 - share/docs/src/commonjs.rst | 56 -- share/docs/src/conf.py | 33 - share/docs/src/config_reference.rst | 288 ------ share/docs/src/configuring.rst | 95 -- share/docs/src/ddocs.rst | 19 - share/docs/src/errors.rst | 37 - share/docs/src/http-proxying.rst | 94 -- share/docs/src/index.rst | 48 - share/docs/src/intro.rst | 309 ------ share/docs/src/json-structure.rst | 413 -------- share/docs/src/os-daemons.rst | 50 - share/docs/src/range.rst | 72 -- share/docs/src/release.rst | 47 - share/docs/src/replication.rst | 383 -------- share/docs/src/ssl.rst | 109 -- 72 files changed, 7986 insertions(+), 7986 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/configure.ac ---------------------------------------------------------------------- diff --git a/configure.ac b/configure.ac index 1431e50..7224b85 100644 --- a/configure.ac +++ b/configure.ac @@ -549,7 +549,7 @@ AC_CONFIG_FILES([etc/logrotate.d/Makefile]) AC_CONFIG_FILES([etc/windows/Makefile]) AC_CONFIG_FILES([etc/Makefile]) AC_CONFIG_FILES([share/Makefile]) -AC_CONFIG_FILES([share/docs/Makefile]) +AC_CONFIG_FILES([share/doc/Makefile]) AC_CONFIG_FILES([src/Makefile]) AC_CONFIG_FILES([src/couch_index/Makefile]) AC_CONFIG_FILES([src/couch_mrview/Makefile]) http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/Makefile.am ---------------------------------------------------------------------- diff --git a/share/Makefile.am b/share/Makefile.am index b71fb73..31373ee 100644 --- a/share/Makefile.am +++ b/share/Makefile.am @@ -10,7 +10,7 @@ ## License for the specific language governing permissions and limitations under ## the License. -SUBDIRS = docs +SUBDIRS = doc JS_FILE = server/main.js http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/Makefile.am ---------------------------------------------------------------------- diff --git a/share/doc/Makefile.am b/share/doc/Makefile.am new file mode 100644 index 0000000..0a039f5 --- /dev/null +++ b/share/doc/Makefile.am @@ -0,0 +1,53 @@ +## Licensed under the Apache License, Version 2.0 (the "License"); you may not +## use this file except in compliance with the License. You may obtain a copy of +## the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +## WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +## License for the specific language governing permissions and limitations under +## the License. + +# @@ can we remove _static? + +# @@ what is the license for conf.py? + +EXTRA_DIST = \ + demo.mk \ + images/epub-icon.png \ + images/futon-createdb.png \ + images/futon-editdoc.png \ + images/futon-editeddoc.png \ + images/futon-overview.png \ + images/futon-replform.png \ + make.bat \ + Makefile.am \ + src/_static \ + src/api/authn.rst \ + src/api/configuration.rst \ + src/api/database.rst \ + src/api/dbmaint.rst \ + src/api/design.rst \ + src/api/documents.rst \ + src/api/local.rst \ + src/api/misc.rst \ + src/api/reference.rst \ + src/api-basics.rst \ + src/changes.rst \ + src/commonjs.rst \ + src/conf.py \ + src/config_reference.rst \ + src/configuring.rst \ + src/ddocs.rst \ + src/errors.rst \ + src/http-proxying.rst \ + src/index.rst \ + src/intro.rst \ + src/json-structure.rst \ + src/os-daemons.rst \ + src/range.rst \ + src/release.rst \ + src/replication.rst \ + src/ssl.rst \ No newline at end of file http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/demo.mk ---------------------------------------------------------------------- diff --git a/share/doc/demo.mk b/share/doc/demo.mk new file mode 100644 index 0000000..28a1541 --- /dev/null +++ b/share/doc/demo.mk @@ -0,0 +1,173 @@ +# Makefile for Sphinx documentation +# + +# You can set these variables from the command line. +SPHINXOPTS = +SPHINXBUILD = sphinx-build +PAPER = +BUILDDIR = build + +# Internal variables. +PAPEROPT_a4 = -D latex_paper_size=a4 +PAPEROPT_letter = -D latex_paper_size=letter +ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) src +# the i18n builder cannot share the environment and doctrees with the others +I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source + +.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext + +help: + @echo "Please use \`make ' where is one of" + @echo " html to make standalone HTML files" + @echo " dirhtml to make HTML files named index.html in directories" + @echo " singlehtml to make a single large HTML file" + @echo " pickle to make pickle files" + @echo " json to make JSON files" + @echo " htmlhelp to make HTML files and a HTML help project" + @echo " qthelp to make HTML files and a qthelp project" + @echo " devhelp to make HTML files and a Devhelp project" + @echo " epub to make an epub" + @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" + @echo " latexpdf to make LaTeX files and run them through pdflatex" + @echo " text to make text files" + @echo " man to make manual pages" + @echo " texinfo to make Texinfo files" + @echo " info to make Texinfo files and run them through makeinfo" + @echo " gettext to make PO message catalogs" + @echo " changes to make an overview of all changed/added/deprecated items" + @echo " linkcheck to check all external links for integrity" + @echo " doctest to run all doctests embedded in the documentation (if enabled)" + +clean: + -rm -rf $(BUILDDIR)/* + +# include +html: + $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html + @echo + @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." + +# exclude, doesn't work locally +dirhtml: + $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml + @echo + @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." + +# maybe include, but not as default option, too big +singlehtml: + $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml + @echo + @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." + +# exclude, no use for this +pickle: + $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle + @echo + @echo "Build finished; now you can process the pickle files." + +# exclude, no use for this +json: + $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json + @echo + @echo "Build finished; now you can process the JSON files." + +# exclude, but mention availability on wiki +htmlhelp: + $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp + @echo + @echo "Build finished; now you can run HTML Help Workshop with the" \ + ".hhp project file in $(BUILDDIR)/htmlhelp." +# exclude +qthelp: + $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp + @echo + @echo "Build finished; now you can run "qcollectiongenerator" with the" \ + ".qhcp project file in $(BUILDDIR)/qthelp, like this:" + @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/CouchDB.qhcp" + @echo "To view the help file:" + @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/CouchDB.qhc" + +# exclude +devhelp: + $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp + @echo + @echo "Build finished." + @echo "To view the help file:" + @echo "# mkdir -p $$HOME/.local/share/devhelp/CouchDB" + @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/CouchDB" + @echo "# devhelp" + +# exclude +epub: + $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub + @echo + @echo "Build finished. The epub file is in $(BUILDDIR)/epub." + +# include +latex: + $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex + @echo + @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." + @echo "Run \`make' in that directory to run these through (pdf)latex" \ + "(use \`make latexpdf' here to do that automatically)." + +# include, replace automake +latexpdf: + $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex + @echo "Running LaTeX files through pdflatex..." + $(MAKE) -C $(BUILDDIR)/latex all-pdf + @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." + +# exclude +text: + $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text + @echo + @echo "Build finished. The text files are in $(BUILDDIR)/text." + +# exclude +man: + $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man + @echo + @echo "Build finished. The manual pages are in $(BUILDDIR)/man." + +# include +texinfo: + $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo + @echo + @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." + @echo "Run \`make' in that directory to run these through makeinfo" \ + "(use \`make info' here to do that automatically)." + +# include, replace automake +info: + $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo + @echo "Running Texinfo files through makeinfo..." + make -C $(BUILDDIR)/texinfo info + @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." + +# exclude, but mention that this is an option on wiki (for translators) +gettext: + $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale + @echo + @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale." + +# hook this into producing the changelog, ooh!! ooh!! +changes: + $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes + @echo + @echo "The overview file is in $(BUILDDIR)/changes." + +# figure out what cloudstack are doing for copyright stuff + +# run this and check for errors, aborting the build +linkcheck: + $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck + @echo + @echo "Link check complete; look for any errors in the above output " \ + "or in $(BUILDDIR)/linkcheck/output.txt." + +# exclude, but mention on the wiki +doctest: + $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest + @echo "Testing of doctests in the sources finished, look at the " \ + "results in $(BUILDDIR)/doctest/output.txt." http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/epub-icon.png ---------------------------------------------------------------------- diff --git a/share/doc/images/epub-icon.png b/share/doc/images/epub-icon.png new file mode 100644 index 0000000..3fda935 Binary files /dev/null and b/share/doc/images/epub-icon.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/futon-createdb.png ---------------------------------------------------------------------- diff --git a/share/doc/images/futon-createdb.png b/share/doc/images/futon-createdb.png new file mode 100644 index 0000000..c8c1b9d Binary files /dev/null and b/share/doc/images/futon-createdb.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/futon-editdoc.png ---------------------------------------------------------------------- diff --git a/share/doc/images/futon-editdoc.png b/share/doc/images/futon-editdoc.png new file mode 100644 index 0000000..6802c2c Binary files /dev/null and b/share/doc/images/futon-editdoc.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/futon-editeddoc.png ---------------------------------------------------------------------- diff --git a/share/doc/images/futon-editeddoc.png b/share/doc/images/futon-editeddoc.png new file mode 100644 index 0000000..5c8b549 Binary files /dev/null and b/share/doc/images/futon-editeddoc.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/futon-overview.png ---------------------------------------------------------------------- diff --git a/share/doc/images/futon-overview.png b/share/doc/images/futon-overview.png new file mode 100644 index 0000000..d1eac6e Binary files /dev/null and b/share/doc/images/futon-overview.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/images/futon-replform.png ---------------------------------------------------------------------- diff --git a/share/doc/images/futon-replform.png b/share/doc/images/futon-replform.png new file mode 100644 index 0000000..d904f0d Binary files /dev/null and b/share/doc/images/futon-replform.png differ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/make.bat ---------------------------------------------------------------------- diff --git a/share/doc/make.bat b/share/doc/make.bat new file mode 100644 index 0000000..4994199 --- /dev/null +++ b/share/doc/make.bat @@ -0,0 +1,190 @@ +@ECHO OFF + +REM Command file for Sphinx documentation + +if "%SPHINXBUILD%" == "" ( + set SPHINXBUILD=sphinx-build +) +set BUILDDIR=build +set ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% source +set I18NSPHINXOPTS=%SPHINXOPTS% source +if NOT "%PAPER%" == "" ( + set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS% + set I18NSPHINXOPTS=-D latex_paper_size=%PAPER% %I18NSPHINXOPTS% +) + +if "%1" == "" goto help + +if "%1" == "help" ( + :help + echo.Please use `make ^` where ^ is one of + echo. html to make standalone HTML files + echo. dirhtml to make HTML files named index.html in directories + echo. singlehtml to make a single large HTML file + echo. pickle to make pickle files + echo. json to make JSON files + echo. htmlhelp to make HTML files and a HTML help project + echo. qthelp to make HTML files and a qthelp project + echo. devhelp to make HTML files and a Devhelp project + echo. epub to make an epub + echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter + echo. text to make text files + echo. man to make manual pages + echo. texinfo to make Texinfo files + echo. gettext to make PO message catalogs + echo. changes to make an overview over all changed/added/deprecated items + echo. linkcheck to check all external links for integrity + echo. doctest to run all doctests embedded in the documentation if enabled + goto end +) + +if "%1" == "clean" ( + for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i + del /q /s %BUILDDIR%\* + goto end +) + +if "%1" == "html" ( + %SPHINXBUILD% -b html %ALLSPHINXOPTS% %BUILDDIR%/html + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The HTML pages are in %BUILDDIR%/html. + goto end +) + +if "%1" == "dirhtml" ( + %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% %BUILDDIR%/dirhtml + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The HTML pages are in %BUILDDIR%/dirhtml. + goto end +) + +if "%1" == "singlehtml" ( + %SPHINXBUILD% -b singlehtml %ALLSPHINXOPTS% %BUILDDIR%/singlehtml + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The HTML pages are in %BUILDDIR%/singlehtml. + goto end +) + +if "%1" == "pickle" ( + %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% %BUILDDIR%/pickle + if errorlevel 1 exit /b 1 + echo. + echo.Build finished; now you can process the pickle files. + goto end +) + +if "%1" == "json" ( + %SPHINXBUILD% -b json %ALLSPHINXOPTS% %BUILDDIR%/json + if errorlevel 1 exit /b 1 + echo. + echo.Build finished; now you can process the JSON files. + goto end +) + +if "%1" == "htmlhelp" ( + %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% %BUILDDIR%/htmlhelp + if errorlevel 1 exit /b 1 + echo. + echo.Build finished; now you can run HTML Help Workshop with the ^ +.hhp project file in %BUILDDIR%/htmlhelp. + goto end +) + +if "%1" == "qthelp" ( + %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% %BUILDDIR%/qthelp + if errorlevel 1 exit /b 1 + echo. + echo.Build finished; now you can run "qcollectiongenerator" with the ^ +.qhcp project file in %BUILDDIR%/qthelp, like this: + echo.^> qcollectiongenerator %BUILDDIR%\qthelp\CouchDB.qhcp + echo.To view the help file: + echo.^> assistant -collectionFile %BUILDDIR%\qthelp\CouchDB.ghc + goto end +) + +if "%1" == "devhelp" ( + %SPHINXBUILD% -b devhelp %ALLSPHINXOPTS% %BUILDDIR%/devhelp + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. + goto end +) + +if "%1" == "epub" ( + %SPHINXBUILD% -b epub %ALLSPHINXOPTS% %BUILDDIR%/epub + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The epub file is in %BUILDDIR%/epub. + goto end +) + +if "%1" == "latex" ( + %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex + if errorlevel 1 exit /b 1 + echo. + echo.Build finished; the LaTeX files are in %BUILDDIR%/latex. + goto end +) + +if "%1" == "text" ( + %SPHINXBUILD% -b text %ALLSPHINXOPTS% %BUILDDIR%/text + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The text files are in %BUILDDIR%/text. + goto end +) + +if "%1" == "man" ( + %SPHINXBUILD% -b man %ALLSPHINXOPTS% %BUILDDIR%/man + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The manual pages are in %BUILDDIR%/man. + goto end +) + +if "%1" == "texinfo" ( + %SPHINXBUILD% -b texinfo %ALLSPHINXOPTS% %BUILDDIR%/texinfo + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The Texinfo files are in %BUILDDIR%/texinfo. + goto end +) + +if "%1" == "gettext" ( + %SPHINXBUILD% -b gettext %I18NSPHINXOPTS% %BUILDDIR%/locale + if errorlevel 1 exit /b 1 + echo. + echo.Build finished. The message catalogs are in %BUILDDIR%/locale. + goto end +) + +if "%1" == "changes" ( + %SPHINXBUILD% -b changes %ALLSPHINXOPTS% %BUILDDIR%/changes + if errorlevel 1 exit /b 1 + echo. + echo.The overview file is in %BUILDDIR%/changes. + goto end +) + +if "%1" == "linkcheck" ( + %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck + if errorlevel 1 exit /b 1 + echo. + echo.Link check complete; look for any errors in the above output ^ +or in %BUILDDIR%/linkcheck/output.txt. + goto end +) + +if "%1" == "doctest" ( + %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest + if errorlevel 1 exit /b 1 + echo. + echo.Testing of doctests in the sources finished, look at the ^ +results in %BUILDDIR%/doctest/output.txt. + goto end +) + +:end http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/src/_static/.gitignore ---------------------------------------------------------------------- diff --git a/share/doc/src/_static/.gitignore b/share/doc/src/_static/.gitignore new file mode 100644 index 0000000..e69de29 http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/src/api-basics.rst ---------------------------------------------------------------------- diff --git a/share/doc/src/api-basics.rst b/share/doc/src/api-basics.rst new file mode 100644 index 0000000..97ea70c --- /dev/null +++ b/share/doc/src/api-basics.rst @@ -0,0 +1,459 @@ +.. Licensed under the Apache License, Version 2.0 (the "License"); you may not +.. use this file except in compliance with the License. You may obtain a copy of +.. the License at +.. +.. http://www.apache.org/licenses/LICENSE-2.0 +.. +.. Unless required by applicable law or agreed to in writing, software +.. distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +.. WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +.. License for the specific language governing permissions and limitations under +.. the License. + +.. _api-basics: + +=========== +CouchDB API +=========== + +The CouchDB API is the primary method of interfacing to a CouchDB +instance. Requests are made using HTTP and requests are used to request +information from the database, store new data, and perform views and +formatting of the information stored within the documents. + +Requests to the API can be categorised by the different areas of the +CouchDB system that you are accessing, and the HTTP method used to send +the request. Different methods imply different operations, for example +retrieval of information from the database is typically handled by the +``GET`` operation, while updates are handled by either a ``POST`` or +``PUT`` request. There are some differences between the information that +must be supplied for the different methods. For a guide to the basic +HTTP methods and request structure, see :ref:`api-format`. + +For nearly all operations, the submitted data, and the returned data +structure, is defined within a JavaScript Object Notation (JSON) object. +Basic information on the content and data types for JSON are provided in +:ref:`json`. + +Errors when accessing the CouchDB API are reported using standard HTTP +Status Codes. A guide to the generic codes returned by CouchDB are +provided in :ref:`errors`. + +When accessing specific areas of the CouchDB API, specific information +and examples on the HTTP methods and request, JSON structures, and error +codes are provided. For a guide to the different areas of the API, see +:ref:`api-overview`. + +.. _api-format: + +Request Format and Responses +============================ + +CouchDB supports the following HTTP request methods: + +- ``GET`` + + Request the specified item. As with normal HTTP requests, the format + of the URL defines what is returned. With CouchDB this can include + static items, database documents, and configuration and statistical + information. In most cases the information is returned in the form of + a JSON document. + +- ``HEAD`` + + The ``HEAD`` method is used to get the HTTP header of a ``GET`` + request without the body of the response. + +- ``POST`` + + Upload data. Within CouchDB ``POST`` is used to set values, including + uploading documents, setting document values, and starting certain + administration commands. + +- ``PUT`` + + Used to put a specified resource. In CouchDB ``PUT`` is used to + create new objects, including databases, documents, views and design + documents. + +- ``DELETE`` + + Deletes the specified resource, including documents, views, and + design documents. + +- ``COPY`` + + A special method that can be used to copy documents and objects. + +If you use the an unsupported HTTP request type with a URL that does not +support the specified type, a 405 error will be returned, listing the +supported HTTP methods. For example: + +.. code-block:: javascript + + { + "error":"method_not_allowed", + "reason":"Only GET,HEAD allowed" + } + + +The CouchDB design document API and the functions when returning HTML +(for example as part of a show or list) enables you to include custom +HTTP headers through the ``headers`` block of the return object. + +HTTP Headers +============ + +Because CouchDB uses HTTP for all communication, you need to ensure that +the correct HTTP headers are supplied (and processed on retrieval) so +that you get the right format and encoding. Different environments and +clients will be more or less strict on the effect of these HTTP headers +(especially when not present). Where possible you should be as specific +as possible. + +Request Headers +--------------- + +- ``Content-type`` + + Specifies the content type of the information being supplied within + the request. The specification uses MIME type specifications. For the + majority of requests this will be JSON (``application/json``). For + some settings the MIME type will be plain text. When uploading + attachments it should be the corresponding MIME type for the + attachment or binary (``application/octet-stream``). + + The use of the ``Content-type`` on a request is highly recommended. + +- ``Accept`` + + Specifies the list of accepted data types to be returned by the + server (i.e. that are accepted/understandable by the client). The + format should be a list of one or more MIME types, separated by + colons. + + For the majority of requests the definition should be for JSON data + (``application/json``). For attachments you can either specify the + MIME type explicitly, or use ``*/*`` to specify that all file types + are supported. If the ``Accept`` header is not supplied, then the + ``*/*`` MIME type is assumed (i.e. client accepts all formats). + + The use of ``Accept`` in queries for CouchDB is not required, but is + highly recommended as it helps to ensure that the data returned can + be processed by the client. + + If you specify a data type using the ``Accept`` header, CouchDB will + honor the specified type in the ``Content-type`` header field + returned. For example, if you explicitly request ``application/json`` + in the ``Accept`` of a request, the returned HTTP headers will use + the value in the returned ``Content-type`` field. + + For example, when sending a request without an explicit ``Accept`` + header, or when specifying ``*/*``: + + .. code-block:: http + + GET /recipes HTTP/1.1 + Host: couchdb:5984 + Accept: */* + + The returned headers are: + + .. code-block:: http + + Server: CouchDB/1.0.1 (Erlang OTP/R13B) + Date: Thu, 13 Jan 2011 13:39:34 GMT + Content-Type: text/plain;charset=utf-8 + Content-Length: 227 + Cache-Control: must-revalidate + + Note that the returned content type is ``text/plain`` even though the + information returned by the request is in JSON format. + + Explicitly specifying the ``Accept`` header: + + .. code-block:: http + + GET /recipes HTTP/1.1 + Host: couchdb:5984 + Accept: application/json + + The headers returned include the ``application/json`` content type: + + .. code-block:: http + + Server: CouchDB/|version| (Erlang OTP/R13B) + Date: Thu, 13 Jan 2011 13:40:11 GMT + Content-Type: application/json + Content-Length: 227 + Cache-Control: must-revalidate + +Response Headers +---------------- + +Response headers are returned by the server when sending back content +and include a number of different header fields, many of which are +standard HTTP response header and have no significance to CouchDB +operation. The list of response headers important to CouchDB are listed +below. + +- ``Content-type`` + + Specifies the MIME type of the returned data. For most request, the + returned MIME type is ``text/plain``. All text is encoded in Unicode + (UTF-8), and this is explicitly stated in the returned + ``Content-type``, as ``text/plain;charset=utf-8``. + +- ``Cache-control`` + + The cache control HTTP response header provides a suggestion for + client caching mechanisms on how to treat the returned information. + CouchDB typically returns the ``must-revalidate``, which indicates + that the information should be revalidated if possible. This is used + to ensure that the dynamic nature of the content is correctly + updated. + +- ``Content-length`` + + The length (in bytes) of the returned content. + +- ``Etag`` + + The ``Etag`` HTTP header field is used to show the revision for a + document, or a view. + + ETags have been assigned to a map/reduce group (the collection of + views in a single design document). Any change to any of the indexes + for those views would generate a new ETag for all view URL's in a + single design doc, even if that specific view's results had not + changed. + + Each ``_view`` URL has its own ETag which only gets updated when + changes are made to the database that effect that index. If the + index for that specific view does not change, that view keeps the + original ETag head (therefore sending back 304 Not Modified more + often). + +.. _json: + +JSON Basics +=========== + +The majority of requests and responses to CouchDB use the JavaScript +Object Notation (JSON) for formatting the content and structure of the +data and responses. + +JSON is used because it is the simplest and easiest to use solution for +working with data within a web browser, as JSON structures can be +evaluated and used as JavaScript objects within the web browser +environment. JSON also integrates with the server-side JavaScript used +within CouchDB. + +JSON supports the same basic types as supported by JavaScript, these +are: + +- Number (either integer or floating-point). + +- String; this should be enclosed by double-quotes and supports Unicode + characters and backslash escaping. For example: + + .. code-block:: javascript + + "A String" + +- Boolean - a ``true`` or ``false`` value. You can use these strings + directly. For example: + + .. code-block:: javascript + + { "value": true} + +- Array - a list of values enclosed in square brackets. For example: + + .. code-block:: javascript + + ["one", "two", "three"] + +- Object - a set of key/value pairs (i.e. an associative array, or + hash). The key must be a string, but the value can be any of the + supported JSON values. For example: + + .. code-block:: javascript + + { + "servings" : 4, + "subtitle" : "Easy to make in advance, and then cook when ready", + "cooktime" : 60, + "title" : "Chicken Coriander" + } + + + In CouchDB, the JSON object is used to represent a variety of + structures, including the main CouchDB document. + +Parsing JSON into a JavaScript object is supported through the +``JSON.parse()`` function in JavaScript, or through various libraries that +will perform the parsing of the content into a JavaScript object for +you. Libraries for parsing and generating JSON are available in many +languages, including Perl, Python, Ruby, Erlang and others. + +.. warning:: + Care should be taken to ensure that your JSON structures are + valid, invalid structures will cause CouchDB to return an HTTP status code + of 500 (server error). + +.. _errors: + +HTTP Status Codes +================= + +With the interface to CouchDB working through HTTP, error codes and +statuses are reported using a combination of the HTTP status code +number, and corresponding data in the body of the response data. + +A list of the error codes returned by CouchDB, and generic descriptions +of the related errors are provided below. The meaning of different +status codes for specific request types are provided in the +corresponding API call reference. + +- ``200 - OK`` + + Request completed successfully. + +- ``201 - Created`` + + Document created successfully. + +- ``202 - Accepted`` + + Request has been accepted, but the corresponding operation may not + have completed. This is used for background operations, such as + database compaction. + +- ``304 - Not Modified`` + + The additional content requested has not been modified. This is used + with the ETag system to identify the version of information returned. + +- ``400 - Bad Request`` + + Bad request structure. The error can indicate an error with the + request URL, path or headers. Differences in the supplied MD5 hash + and content also trigger this error, as this may indicate message + corruption. + +- ``401 - Unauthorized`` + + The item requested was not available using the supplied + authorization, or authorization was not supplied. + +- ``403 - Forbidden`` + + The requested item or operation is forbidden. + +- ``404 - Not Found`` + + The requested content could not be found. The content will include + further information, as a JSON object, if available. The structure + will contain two keys, ``error`` and ``reason``. For example: + + .. code-block:: javascript + + {"error":"not_found","reason":"no_db_file"} + +- ``405 - Resource Not Allowed`` + + A request was made using an invalid HTTP request type for the URL + requested. For example, you have requested a ``PUT`` when a ``POST`` + is required. Errors of this type can also triggered by invalid URL + strings. + +- ``406 - Not Acceptable`` + + The requested content type is not supported by the server. + +- ``409 - Conflict`` + + Request resulted in an update conflict. + +- ``412 - Precondition Failed`` + + The request headers from the client and the capabilities of the + server do not match. + +- ``415 - Bad Content Type`` + + The content types supported, and the content type of the information + being requested or submitted indicate that the content type is not + supported. + +- ``416 - Requested Range Not Satisfiable`` + + The range specified in the request header cannot be satisfied by the + server. + +- ``417 - Expectation Failed`` + + When sending documents in bulk, the bulk load operation failed. + +- ``500 - Internal Server Error`` + + The request was invalid, either because the supplied JSON was + invalid, or invalid information was supplied as part of the request. + +.. _api-overview: + +CouchDB API Overview +==================== + +The components of the API URL path help determine the part of the +CouchDB server that is being accessed. The result is the structure of +the URL request both identifies and effectively describes the area of +the database you are accessing. + +As with all URLs, the individual components are separated by a forward +slash. + +As a general rule, URL components and JSON fields starting with the +``_`` (underscore) character represent a special component or entity +within the server or returned object. For example, the URL fragment +``/_all_dbs`` gets a list of all of the databases in a CouchDB instance. + +The remainder of the URL API structure can be divided up according to +the URL structure. The different sections are divided as follows: + +- ``/db`` + + Database methods, related to adding, updating or deleting databases, + and setting database parameters and operations. For more detailed + information, see :ref:`api-db`. + +- ``/db/doc`` + + Document methods, those that create, store, update or delete CouchDB + documents and their attachments. For more information, see :ref:`api-doc`. + +- ``/db/_local/local-doc`` + + Document methods, those that create, store, update or delete CouchDB + documents only within the local database. Local documents are not + synchronized with other databases. For more information, see + :ref:`api-local`. + +- ``/db/_design/design-doc`` + + Design documents provide the methods and structure for recovering + information from a CouchDB database in the form of views, shows and + lists. For more information, see :ref:`api-design`. + +- ``/_special`` + + Special methods that obtain or set information about the CouchDB + instance, including methods for configuring replication, accessing + the logs, and generate Universally Unique IDs (UUIDs). For more + information, see :ref:`api-misc`. + +- ``/_config`` + + Methods for getting, and settings, CouchDB configuration parameters. + For more information, see :ref:`api-config`. http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/src/api/authn.rst ---------------------------------------------------------------------- diff --git a/share/doc/src/api/authn.rst b/share/doc/src/api/authn.rst new file mode 100644 index 0000000..bac198b --- /dev/null +++ b/share/doc/src/api/authn.rst @@ -0,0 +1,41 @@ +.. Licensed under the Apache License, Version 2.0 (the "License"); you may not +.. use this file except in compliance with the License. You may obtain a copy of +.. the License at +.. +.. http://www.apache.org/licenses/LICENSE-2.0 +.. +.. Unless required by applicable law or agreed to in writing, software +.. distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +.. WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +.. License for the specific language governing permissions and limitations under +.. the License. + +====================== +Authentication Methods +====================== + +.. todo:: Authentication Methods + +The CouchDB Authentication methods provide an interface for obtaining +session and authorization data. + +A list of the available methods and URL paths are provided below: + ++--------+-------------------------+-------------------------------------------+ +| Method | Path | Description | ++========+=========================+===========================================+ +| GET | /_oauth/access_token | TBC | ++--------+-------------------------+-------------------------------------------+ +| GET | /_oauth/authorize | TBC | ++--------+-------------------------+-------------------------------------------+ +| POST | /_oauth/authorize | TBC | ++--------+-------------------------+-------------------------------------------+ +| GET | /_oauth/request_token | TBC | ++--------+-------------------------+-------------------------------------------+ +| GET | /_session | Returns cookie based login user | +| | | information | ++--------+-------------------------+-------------------------------------------+ +| POST | /_session | Do cookie based user login | ++--------+-------------------------+-------------------------------------------+ +| DELETE | /_session | Logout cookie based user | ++--------+-------------------------+-------------------------------------------+ http://git-wip-us.apache.org/repos/asf/couchdb/blob/c9efdb1b/share/doc/src/api/configuration.rst ---------------------------------------------------------------------- diff --git a/share/doc/src/api/configuration.rst b/share/doc/src/api/configuration.rst new file mode 100644 index 0000000..6c2c588 --- /dev/null +++ b/share/doc/src/api/configuration.rst @@ -0,0 +1,297 @@ +.. Licensed under the Apache License, Version 2.0 (the "License"); you may not +.. use this file except in compliance with the License. You may obtain a copy of +.. the License at +.. +.. http://www.apache.org/licenses/LICENSE-2.0 +.. +.. Unless required by applicable law or agreed to in writing, software +.. distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +.. WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +.. License for the specific language governing permissions and limitations under +.. the License. + +.. _api-config: + +===================== +Configuration Methods +===================== + +The CouchDB API Server Configuration Methods provide an interface to +query and update the various configuration values within a running +CouchDB instance. + +A list of the available methods and URL paths are provided below: + ++--------+-------------------------+-------------------------------------------+ +| Method | Path | Description | ++========+=========================+===========================================+ +| GET | /_config | Obtain a list of the entire server | +| | | configuration | ++--------+-------------------------+-------------------------------------------+ +| GET | /_config/section | Get all the configuration values for the | +| | | specified section | ++--------+-------------------------+-------------------------------------------+ +| GET | /_config/section/key | Get a specific section/configuration value| ++--------+-------------------------+-------------------------------------------+ +| PUT | /_config/section/key | Set the specified configuration value | ++--------+-------------------------+-------------------------------------------+ +| DELETE | /_config/section/key | Delete the current setting | ++--------+-------------------------+-------------------------------------------+ + +``GET /_config`` +================ + +* **Method**: ``GET /_config`` +* **Request**: None +* **Response**: Returns a structure configuration name and value pairs, + organized by section +* **Admin Privileges Required**: yes +* **Return Codes**: + + * **200**: + Request completed successfully. + +Returns the entire CouchDB server configuration as a JSON structure. The +structure is organized by different configuration sections, with +individual values. + +For example, to get the configuration for a server: + +.. code-block:: http + + GET http://couchdb:5984/_config + Accept: application/json + +The response is the JSON structure: + +.. code-block:: javascript + + { + "query_server_config" : { + "reduce_limit" : "true" + }, + "couchdb" : { + "os_process_timeout" : "5000", + "max_attachment_chunk_size" : "4294967296", + "max_document_size" : "4294967296", + "uri_file" : "/var/lib/couchdb/couch.uri", + "max_dbs_open" : "100", + "view_index_dir" : "/var/lib/couchdb", + "util_driver_dir" : "/usr/lib64/couchdb/erlang/lib/couch-1.0.1/priv/lib", + "database_dir" : "/var/lib/couchdb", + "delayed_commits" : "true" + }, + "attachments" : { + "compressible_types" : "text/*, application/javascript, application/json, application/xml", + "compression_level" : "8" + }, + "uuids" : { + "algorithm" : "utc_random" + }, + "daemons" : { + "view_manager" : "{couch_view, start_link, []}", + "auth_cache" : "{couch_auth_cache, start_link, []}", + "uuids" : "{couch_uuids, start, []}", + "stats_aggregator" : "{couch_stats_aggregator, start, []}", + "query_servers" : "{couch_query_servers, start_link, []}", + "httpd" : "{couch_httpd, start_link, []}", + "stats_collector" : "{couch_stats_collector, start, []}", + "db_update_notifier" : "{couch_db_update_notifier_sup, start_link, []}", + "external_manager" : "{couch_external_manager, start_link, []}" + }, + "stats" : { + "samples" : "[0, 60, 300, 900]", + "rate" : "1000" + }, + "httpd" : { + "vhost_global_handlers" : "_utils, _uuids, _session, _oauth, _users", + "secure_rewrites" : "true", + "authentication_handlers" : "{couch_httpd_oauth, oauth_authentication_handler}, + {couch_httpd_auth, cookie_authentication_handler}, + {couch_httpd_auth, default_authentication_handler}", + "port" : "5984", + "default_handler" : "{couch_httpd_db, handle_request}", + "allow_jsonp" : "false", + "bind_address" : "192.168.0.2", + "max_connections" : "2048" + }, + "query_servers" : { + "javascript" : "/usr/bin/couchjs /usr/share/couchdb/server/main.js" + }, + "couch_httpd_auth" : { + "authentication_db" : "_users", + "require_valid_user" : "false", + "authentication_redirect" : "/_utils/session.html", + "timeout" : "600", + "auth_cache_size" : "50" + }, + "httpd_db_handlers" : { + "_design" : "{couch_httpd_db, handle_design_req}", + "_compact" : "{couch_httpd_db, handle_compact_req}", + "_view_cleanup" : "{couch_httpd_db, handle_view_cleanup_req}", + "_temp_view" : "{couch_httpd_view, handle_temp_view_req}", + "_changes" : "{couch_httpd_db, handle_changes_req}" + }, + "replicator" : { + "max_http_sessions" : "10", + "max_http_pipeline_size" : "10" + }, + "log" : { + "include_sasl" : "true", + "level" : "info", + "file" : "/var/log/couchdb/couch.log" + }, + "httpd_design_handlers" : { + "_update" : "{couch_httpd_show, handle_doc_update_req}", + "_show" : "{couch_httpd_show, handle_doc_show_req}", + "_info" : "{couch_httpd_db, handle_design_info_req}", + "_list" : "{couch_httpd_show, handle_view_list_req}", + "_view" : "{couch_httpd_view, handle_view_req}", + "_rewrite" : "{couch_httpd_rewrite, handle_rewrite_req}" + }, + "httpd_global_handlers" : { + "_replicate" : "{couch_httpd_misc_handlers, handle_replicate_req}", + "/" : "{couch_httpd_misc_handlers, handle_welcome_req, <<\"Welcome\">>}", + "_config" : "{couch_httpd_misc_handlers, handle_config_req}", + "_utils" : "{couch_httpd_misc_handlers, handle_utils_dir_req, \"/usr/share/couchdb/www\"}", + "_active_tasks" : "{couch_httpd_misc_handlers, handle_task_status_req}", + "_session" : "{couch_httpd_auth, handle_session_req}", + "_log" : "{couch_httpd_misc_handlers, handle_log_req}", + "favicon.ico" : "{couch_httpd_misc_handlers, handle_favicon_req, \"/usr/share/couchdb/www\"}", + "_all_dbs" : "{couch_httpd_misc_handlers, handle_all_dbs_req}", + "_oauth" : "{couch_httpd_oauth, handle_oauth_req}", + "_restart" : "{couch_httpd_misc_handlers, handle_restart_req}", + "_uuids" : "{couch_httpd_misc_handlers, handle_uuids_req}", + "_stats" : "{couch_httpd_stats_handlers, handle_stats_req}" + } + } + + +``GET /_config/section`` +======================== + +* **Method**: ``GET /_config/section`` +* **Request**: None +* **Response**: All the configuration values within a specified section +* **Admin Privileges Required**: yes +* **Return Codes**: + + * **200**: + Request completed successfully. + +Gets the configuration structure for a single section. For example, to +retrieve the CouchDB configuration section values: + +.. code-block:: http + + GET http://couchdb:5984/_config/couchdb + Accept: application/json + +The returned JSON contains just the configuration values for this +section: + +.. code-block:: javascript + + { + "os_process_timeout" : "5000", + "max_attachment_chunk_size" : "4294967296", + "max_document_size" : "4294967296", + "uri_file" : "/var/lib/couchdb/couch.uri", + "max_dbs_open" : "100", + "view_index_dir" : "/var/lib/couchdb", + "util_driver_dir" : "/usr/lib64/couchdb/erlang/lib/couch-1.0.1/priv/lib", + "database_dir" : "/var/lib/couchdb", + "delayed_commits" : "true" + } + +``GET /_config/section/key`` +============================ + +* **Method**: ``GET /_config/section/key`` +* **Request**: None +* **Response**: Value of the specified key/section +* **Admin Privileges Required**: yes +* **Return Codes**: + + * **200**: + Request completed successfully. + +Gets a single configuration value from within a specific configuration +section. For example, to obtain the current log level: + +.. code-block:: http + + GET http://couchdb:5984/_config/log/level + Accept: application/json + +Returns the string of the log level: + +.. code-block:: javascript + + "info" + +.. note:: + The returned value will be the JSON of the value, which may be a + string or numeric value, or an array or object. Some client + environments may not parse simple strings or numeric values as valid JSON. + +.. _api-put-config: + +``PUT /_config/section/key`` +============================ + +* **Method**: ``PUT /_config/section/key`` +* **Request**: Value structure +* **Response**: Previous value +* **Admin Privileges Required**: yes +* **Return Codes**: + + * **200**: + Configuration option updated successfully + + * **500**: + Error setting configuration + +Updates a configuration value. The new value should be supplied in the +request body in the corresponding JSON format. For example, if you are +setting a string value, you must supply a valid JSON string. + +For example, to set the function used to generate UUIDs by the +``GET /_uuids`` API call to use the ``utc_random`` generator: + +.. code-block:: http + + PUT http://couchdb:5984/_config/uuids/algorithm + Content-Type: application/json + + "utc_random" + +The return value will be empty, with the response code indicating the +success or failure of the configuration setting. + +``DELETE /_config/section/key`` +=============================== + +* **Method**: ``DELETE /_config/section/key`` +* **Request**: None +* **Response**: Previous value +* **Admin Privileges Required**: yes +* **Return Codes**: + + * **409**: + Supplied revision is incorrect or missing + +Deletes a configuration value. The returned JSON will be the value of +the configuration parameter before it was deleted. For example, to +delete the UUID parameter: + +.. code-block:: http + + DELETE http://couchdb:5984/_config/uuids/algorithm + Content-Type: application/json + +The returned value is the last configured UUID function: + +.. code-block:: javascript + + "random"