Module couchdb_server


The couchdb_server module contains functionality listed under CouchDB API Reference section 1.4.1.

Description

The couchdb_server module contains functionality listed under CouchDB API Reference section 1.4.1.

The Server module contains mainly maintenace and stats related functionality.

Function Index

active_tasks/0List of running tasks, including the task type, name, status and process ID.
all_dbs/1get list of databases on a CouchDB node.
all_dbs/2get list of databases on a CouchDB node with optional filter.
info/1Get Information from the server.
replicate/2Request, configure, or stop, a replication operation.
replicate/3Handle replication.
replicate/4handle Replication.

Function Details

active_tasks/0

active_tasks() -> any()

List of running tasks, including the task type, name, status and process ID.

all_dbs/1

all_dbs(Server::server()) -> {ok, iolist()}

get list of databases on a CouchDB node

all_dbs/2

all_dbs(Server::server(), Options::view_options()) -> {ok, iolist()}

get list of databases on a CouchDB node with optional filter

info/1

info(Server::server()) -> {ok, iolist()}

Get Information from the server

replicate/2

replicate(Server::server(), RepObj::{list()}) -> {ok, term()} | {error, term()}

Request, configure, or stop, a replication operation. It allows to pass for authentication info

  RepObj = {[
  {<<"source">>, <<"sourcedb">>},
  {<<"target">>, <<"targetdb">>},
  {<<"create_target">>, true}
  ]}
  replicate(Server, RepObj).

replicate/3

replicate(Server::server(), Source::binary(), Target::term()) -> {ok, term()} | {error, term()}

Handle replication.

replicate/4

replicate(Server, Source, Target, Options) -> any()

handle Replication. Allows to pass options with source and target. Options is a Json object. ex:

  Options = [{<<"create_target">>, true}]}
  couchdb:replicate(S, "testdb", "testdb2", Options).


erlang logo

Made with EDoc-S