couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Scott Weber <>
Subject Re: Replication of attachment is extremely slow.. LOGGED INFORMATION
Date Fri, 24 Jan 2014 21:03:58 GMT
Ah.  Now we have something.

It was really easy to change the PHP script and re-run the batch file.  Over and over. 
So I have a bunch of tests.

When the script was modified to use only the names "to" and "from"  It worked fast... Really
fast.  But any combination of the "localhost" was very long.

  "source" : "http://localhost:5984/from"
  "target" : "http://localhost:5984/to"
60 seconds

  "source" : "http://localhost:5984/from"
  "target" : "to"
60 seconds

  "source" : "from"
  "target" : "http://localhost:5984/to"
40 seconds 

  "source" : "from"
  "target" : "to"
2 seconds

Replacing "localhost" with cut about 10 seconds off.

  "source" : ""
  "target" : ""
60 seconds  (well, it didn't cut any time off this one)

  "source" : ""
  "target" : "to"
40 seconds

  "source" : "from"
  "target" : ""
30 seconds  

And lastly:  "source" : "http://localhost:5984/from"
  "target" : ""
60 seconds

So localhost is basically the same as  
And any permutation of using the url causes delays.

Sounds like it should fall under "also fun".

Thanks so far. It appears this may be solvable.


----- Original Message -----
From: Paul Davis <>
To: "" <>; Scott Weber <>
Cc: "" <>
Sent: Friday, January 24, 2014 2:25 PM
Subject: Re: Replication of attachment is extremely slow.. LOGGED INFORMATION

The important thing to note here is that test 1 is using URLs for
databases where tests 2 and 3 are using internal replication. Reading
the logs it shows that the request to write the attachment took about
72 seconds. Out of curiosity could you rerun test 3 twice more with
the following JSON bodies:

{"from":"http://localhost:5984/from", "to":"to"}
{"from":"from", "to":"http://localhost:5984/to"}

This should narrow down if there's a problem with reading attachments,
writing attachments, or some weird interplay between reading and
writing attachments.

If it turns out that the only slow version is when both are using the
"http://localhost:5984/dbname" versions then can you run one more

{"from":"", "to":"http://localhost:5984/to"}

If that's also slow then we probably have a weird problem with the
multipart code (fun!). If its not slow then most likely this is a bug
in the HTTP worker pool implementation (also fun!).

View raw message