summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Newson <rnewson@apache.org>2014-02-13 17:09:00 +0000
committerRobert Newson <rnewson@apache.org>2014-02-13 17:09:00 +0000
commit90a989ad89db8efbbbfc667086f977ff0a736668 (patch)
tree4ae93909aff4278f48ec3d805cbe45ad86d96ce2
parentc6c37945920983d0c2dec01e1cf85398bad58a52 (diff)
downloadcouchdb-90a989ad89db8efbbbfc667086f977ff0a736668.tar.gz
Revert "Allow runtime configuration of maximum url length in replication"
This reverts commit e1453abf7d8075906abaf240d8f31465a94b6b25.
-rw-r--r--src/couch_replicator/src/couch_replicator_api_wrap.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/couch_replicator/src/couch_replicator_api_wrap.erl b/src/couch_replicator/src/couch_replicator_api_wrap.erl
index 5a42bb31b..52e15b7fa 100644
--- a/src/couch_replicator/src/couch_replicator_api_wrap.erl
+++ b/src/couch_replicator/src/couch_replicator_api_wrap.erl
@@ -536,11 +536,11 @@ options_to_query_args([{open_revs, Revs} | Rest], Acc) ->
options_to_query_args(Rest, [{"open_revs", JsonRevs} | Acc]).
+-define(MAX_URL_LEN, 7000).
+
atts_since_arg(_UrlLen, [], Acc) ->
lists:reverse(Acc);
atts_since_arg(UrlLen, [PA | Rest], Acc) ->
- MaxUrlLen = list_to_integer(
- couch_config:get("replicator", "max_url_len", "7000")),
RevStr = couch_doc:rev_to_str(PA),
NewUrlLen = case Rest of
[] ->
@@ -550,7 +550,7 @@ atts_since_arg(UrlLen, [PA | Rest], Acc) ->
% plus 2 double quotes and a comma (% encoded)
UrlLen + size(RevStr) + 9
end,
- case NewUrlLen >= MaxUrlLen of
+ case NewUrlLen >= ?MAX_URL_LEN of
true ->
lists:reverse(Acc);
false ->