Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
enable feed=eventsource for /_db_updates
The fix is adding `eventsource` to the allowed options to
/_db_updates?feed=eventsource, since the underlying implementation
is a global database’s _changes feed.

Closes COUCHDB-2665
  • Loading branch information
janl committed Apr 17, 2016
1 parent e55de37 commit f9cd1d9eb9ed26f7275c33c38623d0a50e9ac44d
Showing 1 changed file with 2 additions and 2 deletions.
@@ -57,10 +57,10 @@ handle_global_changes_req(#httpd{method='GET'}=Req) ->
chttpd:etag_respond(Req, Etag, fun() ->
fabric:changes(Db, fun changes_callback/2, Acc#acc{etag=Etag}, Options1)
end);
Feed when Feed =:= "continuous"; Feed =:= "longpoll" ->
Feed when Feed =:= "continuous"; Feed =:= "longpoll"; Feed =:= "eventsource" ->
fabric:changes(Db, fun changes_callback/2, Acc, Options1);
_ ->
Msg = <<"Supported `feed` types: normal, continuous, longpoll">>,
Msg = <<"Supported `feed` types: normal, continuous, longpoll, eventsource">>,
throw({bad_request, Msg})
end;
handle_global_changes_req(Req) ->

0 comments on commit f9cd1d9

Please sign in to comment.