You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by va...@apache.org on 2020/06/12 18:21:37 UTC
[couchdb] branch prototype/fdb-layer updated: add back r and w
options
This is an automated email from the ASF dual-hosted git repository.
vatamane pushed a commit to branch prototype/fdb-layer
in repository https://gitbox.apache.org/repos/asf/couchdb.git
The following commit(s) were added to refs/heads/prototype/fdb-layer by this push:
new 3423d19 add back r and w options
3423d19 is described below
commit 3423d1936d918598fbe434a3382dd93ae4d0228a
Author: Tony Sun <to...@gmail.com>
AuthorDate: Fri Jun 12 11:02:48 2020 -0700
add back r and w options
---
src/mango/src/mango_opts.erl | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/src/mango/src/mango_opts.erl b/src/mango/src/mango_opts.erl
index e357676..7bae9c9 100644
--- a/src/mango/src/mango_opts.erl
+++ b/src/mango/src/mango_opts.erl
@@ -64,6 +64,12 @@ validate_idx_create({Props}) ->
{optional, true},
{default, auto_name},
{validator, fun validate_idx_name/1}
+ ]},
+ {<<"w">>, [
+ {tag, w},
+ {optional, true},
+ {default, 2},
+ {validator, fun is_pos_integer/1}
]}
],
validate(Props, Opts).
@@ -111,6 +117,12 @@ validate_find({Props}) ->
{default, []},
{validator, fun validate_fields/1}
]},
+ {<<"r">>, [
+ {tag, r},
+ {optional, true},
+ {default, 1},
+ {validator, fun mango_opts:is_pos_integer/1}
+ ]},
{<<"conflicts">>, [
{tag, conflicts},
{optional, true},