nickva commented on code in PR #4284:
URL: https://github.com/apache/couchdb/pull/4284#discussion_r1038348391


##########
src/couch_replicator/src/couch_replicator_scheduler_job.erl:
##########
@@ -406,6 +417,18 @@ terminate({shutdown, max_backoff}, State) ->
     ),
     terminate_cleanup(State),
     couch_replicator_notifier:notify({error, RepId, max_backoff});
+terminate({shutdown, {duplicate_job, OtherPid}}, State) ->
+    #rep_state{
+        source_name = Source,
+        target_name = Target,
+        rep_details = #rep{id = {BaseId, Ext} = RepId}
+    } = State,
+    couch_log:error(
+        "Replication `~s` (`~s` -> `~s`) with pid ~p was usurped by ~p on node 
~p",

Review Comment:
   I saw in another log line in couch_replicator_doc_processor and thought it 
sounded great!
   
   In the logs it looks like:
   ```
   [notice] Starting replication 17f4ee1a38b4e4e77a6e1b69f2bcfb06+continuous ...
   
   [error]  Replication `17f4ee1a38b4e4e77a6e1b69f2bcfb06+continuous` 
      (`http://127.0.0.1:61447/eunit-test-db-184e35ec5e1ba8c30d28be2783438031/` 
-> 
         
`http://127.0.0.1:61447/eunit-test-db-bf60295c8cb46108c52c9a32d6ee6a1e/`)
     with pid <0.5230.0> was usurped by <18199.89.0> on node 'A@1'
   ```
   (From couch_replicator/.eunit/couch.log)
   
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to