You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by fd...@apache.org on 2011/06/23 18:12:56 UTC
svn commit: r1138964 - /couchdb/trunk/src/couchdb/couch_replicator.erl
Author: fdmanana
Date: Thu Jun 23 16:12:56 2011
New Revision: 1138964
URL: http://svn.apache.org/viewvc?rev=1138964&view=rev
Log:
Improve replication logging and status report
When resuming a replication, log and report what's the start
sequence number (stored in latest checkpoint)
Modified:
couchdb/trunk/src/couchdb/couch_replicator.erl
Modified: couchdb/trunk/src/couchdb/couch_replicator.erl
URL: http://svn.apache.org/viewvc/couchdb/trunk/src/couchdb/couch_replicator.erl?rev=1138964&r1=1138963&r2=1138964&view=diff
==============================================================================
--- couchdb/trunk/src/couchdb/couch_replicator.erl (original)
+++ couchdb/trunk/src/couchdb/couch_replicator.erl Thu Jun 23 16:12:56 2011
@@ -257,7 +257,13 @@ do_init(#rep{options = Options, id = {Ba
couch_task_status:add_task(
"Replication",
io_lib:format("`~s`: `~s` -> `~s`",
- [BaseId ++ Ext, SourceName, TargetName]), "Starting"),
+ [BaseId ++ Ext, SourceName, TargetName]),
+ "Starting" ++ case StartSeq of
+ ?LOWEST_SEQ ->
+ "";
+ _ ->
+ " (from source sequence " ++ integer_to_list(StartSeq) ++ ")"
+ end),
% Until OTP R14B03:
%
@@ -274,10 +280,16 @@ do_init(#rep{options = Options, id = {Ba
"~ca worker batch size of ~p~n"
"~c~p HTTP connections, each with a pipeline size of ~p~n"
"~ca connection timeout of ~p milliseconds~n"
- "~csocket options are: ~s",
+ "~csocket options are: ~s~s",
[BaseId ++ Ext, $\t, CopiersCount, $\t, BatchSize, $\t, MaxHttpConns,
HttpPipeSize, $\t, get_value(connection_timeout, Options),
- $\t, io_lib:format("~p", [get_value(socket_options, Options)])]),
+ $\t, io_lib:format("~p", [get_value(socket_options, Options)]),
+ case StartSeq of
+ ?LOWEST_SEQ ->
+ "";
+ _ ->
+ io_lib:format("~n~csource start sequence ~p", [$\t, StartSeq])
+ end]),
?LOG_DEBUG("Missing rev finder pids are: ~p", [MissingRevFinders]),
?LOG_DEBUG("Worker pids are: ~p", [Workers]),