couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kocol...@apache.org
Subject svn commit: r832807 - in /couchdb/branches/0.9.x: CHANGES NEWS acinclude.m4.in src/couchdb/couch_rep.erl
Date Wed, 04 Nov 2009 17:33:39 GMT
Author: kocolosk
Date: Wed Nov  4 17:33:38 2009
New Revision: 832807

URL: http://svn.apache.org/viewvc?rev=832807&view=rev
Log:
fix replication with 0.10 servers and add a User-Agent header. COUCHDB-559

Modified:
    couchdb/branches/0.9.x/CHANGES
    couchdb/branches/0.9.x/NEWS
    couchdb/branches/0.9.x/acinclude.m4.in
    couchdb/branches/0.9.x/src/couchdb/couch_rep.erl

Modified: couchdb/branches/0.9.x/CHANGES
URL: http://svn.apache.org/viewvc/couchdb/branches/0.9.x/CHANGES?rev=832807&r1=832806&r2=832807&view=diff
==============================================================================
--- couchdb/branches/0.9.x/CHANGES (original)
+++ couchdb/branches/0.9.x/CHANGES Wed Nov  4 17:33:38 2009
@@ -1,6 +1,11 @@
 Apache CouchDB CHANGES
 ======================
 
+Version 0.9.2
+-------------
+
+ * Fix replication with 0.10+ servers initiated by an 0.9 server (COUCHDB-559).
+
 Version 0.9.1
 -------------
 

Modified: couchdb/branches/0.9.x/NEWS
URL: http://svn.apache.org/viewvc/couchdb/branches/0.9.x/NEWS?rev=832807&r1=832806&r2=832807&view=diff
==============================================================================
--- couchdb/branches/0.9.x/NEWS (original)
+++ couchdb/branches/0.9.x/NEWS Wed Nov  4 17:33:38 2009
@@ -7,6 +7,11 @@
 
 Each release section notes when backwards incompatible changes have been made.
 
+Version 0.9.2
+-------------
+
+ * Fix replication with 0.10+ servers initiated by an 0.9 server.
+
 Version 0.9.1
 -------------
 

Modified: couchdb/branches/0.9.x/acinclude.m4.in
URL: http://svn.apache.org/viewvc/couchdb/branches/0.9.x/acinclude.m4.in?rev=832807&r1=832806&r2=832807&view=diff
==============================================================================
--- couchdb/branches/0.9.x/acinclude.m4.in (original)
+++ couchdb/branches/0.9.x/acinclude.m4.in Wed Nov  4 17:33:38 2009
@@ -18,7 +18,7 @@
 m4_define([LOCAL_BUG_URI], [https://issues.apache.org/jira/browse/COUCHDB])
 m4_define([LOCAL_VERSION_MAJOR], [0])
 m4_define([LOCAL_VERSION_MINOR], [9])
-m4_define([LOCAL_VERSION_REVISION], [1])
+m4_define([LOCAL_VERSION_REVISION], [2])
 m4_define([LOCAL_VERSION_STAGE], [])
 m4_define([LOCAL_VERSION_RELEASE], [%release%])
 m4_define([LOCAL_VERSION_PRIMARY],

Modified: couchdb/branches/0.9.x/src/couchdb/couch_rep.erl
URL: http://svn.apache.org/viewvc/couchdb/branches/0.9.x/src/couchdb/couch_rep.erl?rev=832807&r1=832806&r2=832807&view=diff
==============================================================================
--- couchdb/branches/0.9.x/src/couchdb/couch_rep.erl (original)
+++ couchdb/branches/0.9.x/src/couchdb/couch_rep.erl Wed Nov  4 17:33:38 2009
@@ -552,7 +552,7 @@
     ?LOG_ERROR("couch_rep HTTP ~p request failed after 10 retries: ~s", 
         [Action, Url]),
     exit({http_request_failed, Url});
-do_http_request(Url, Action, Headers, JsonBody, Retries) ->
+do_http_request(Url, Action, Headers0, JsonBody, Retries) ->
     ?LOG_DEBUG("couch_rep HTTP ~p request: ~s", [Action, Url]),
     Body =
     case JsonBody of
@@ -561,6 +561,12 @@
     _ ->
         iolist_to_binary(?JSON_ENCODE(JsonBody))
     end,
+    Headers = case proplists:get_value("User-Agent", Headers0) of
+    undefined ->
+        [{"User-Agent","CouchDB/"++couch_server:get_version()} | Headers0];
+    _ ->
+        Headers0
+    end,
     Options = case Action of
         get -> [];
         _ -> [{transfer_encoding, {chunked, 65535}}]
@@ -631,7 +637,7 @@
             
 get_db_info(#http_db{uri=DbUrl, headers=Headers}) ->
     {DbProps} = do_http_request(DbUrl, get, Headers),
-    {ok, [{list_to_existing_atom(?b2l(K)), V} || {K,V} <- DbProps]};
+    {ok, [{list_to_atom(?b2l(K)), V} || {K,V} <- DbProps]};
 get_db_info(Db) ->
     couch_db:get_db_info(Db).
 



Mime
View raw message