couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rnew...@apache.org
Subject [33/50] fabric commit: updated refs/heads/master to a71701c
Date Thu, 28 Aug 2014 12:21:08 GMT
Throw errors when starting changes streams

Previously we were calling the user supplied callback on these errors
which caused a badmatch in keep_sending_changes. This just throws the
error and lets chttpd handle formatting it for the user.

BugzId: 26122


Project: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/commit/4d9106e8
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/tree/4d9106e8
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/diff/4d9106e8

Branch: refs/heads/master
Commit: 4d9106e81176fffa0db7960048229c30b474b3dc
Parents: 8edaa88
Author: Paul J. Davis <paul.joseph.davis@gmail.com>
Authored: Thu Dec 12 12:45:10 2013 -0600
Committer: Robert Newson <rnewson@apache.org>
Committed: Fri Aug 1 15:33:43 2014 +0100

----------------------------------------------------------------------
 src/fabric_view_changes.erl | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fabric/blob/4d9106e8/src/fabric_view_changes.erl
----------------------------------------------------------------------
diff --git a/src/fabric_view_changes.erl b/src/fabric_view_changes.erl
index 1797539..480f6bb 100644
--- a/src/fabric_view_changes.erl
+++ b/src/fabric_view_changes.erl
@@ -174,8 +174,10 @@ send_changes(DbName, ChangesArgs, Callback, PackedSeqs, AccIn, Timeout)
->
                 after
                     fabric_util:cleanup(Workers)
                 end;
+            {error, Reason} ->
+                throw({error, Reason});
             Else ->
-                Callback(Else, AccIn)
+                throw({error, Else})
         end
     after
         rexi_monitor:stop(RexiMon)


Mime
View raw message