diff options
author | Adam Kocoloski <adam@cloudant.com> | 2013-10-02 17:00:16 -0400 |
---|---|---|
committer | Adam Kocoloski <adam@cloudant.com> | 2013-10-02 17:00:16 -0400 |
commit | df0423b5d5c35170626cfc0c10216d2e72e3a83e (patch) | |
tree | e607f3190d87501755b6ef44fb73b7d871c09f56 | |
parent | a72d1f9c895ddfed00f27820a9b46e17d50515c9 (diff) | |
download | couchdb-1901-atomic-multipart-retries.tar.gz |
Bubble up missing_stub exceptions for proper retry1901-atomic-multipart-retries
A missing_stub exception is special in that the replicator retries the
request without the atts_since optimmization.
COUCHDB-1901
-rw-r--r-- | src/couch_replicator/src/couch_replicator_api_wrap.erl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/couch_replicator/src/couch_replicator_api_wrap.erl b/src/couch_replicator/src/couch_replicator_api_wrap.erl index eb7d84504..52e15b7fa 100644 --- a/src/couch_replicator/src/couch_replicator_api_wrap.erl +++ b/src/couch_replicator/src/couch_replicator_api_wrap.erl @@ -215,6 +215,8 @@ open_doc_revs(#httpdb{} = HttpDb, Id, Revs, Options, Fun, Acc) -> receive {'DOWN', Ref, process, Pid, {exit_ok, Ret}} -> Ret; + {'DOWN', Ref, process, Pid, {{nocatch, {missing_stub,_} = Stub}, _}} -> + throw(Stub); {'DOWN', Ref, process, Pid, Else} -> Url = couch_util:url_strip_password( couch_replicator_httpc:full_url(HttpDb, [{path,Path}, {qs,QS}]) |