You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2020/02/17 21:46:35 UTC

[GitHub] [couchdb] nickva opened a new pull request #2562: Re-use changes feed main transaction when including docs

nickva opened a new pull request #2562: Re-use changes feed main transaction when including docs
URL: https://github.com/apache/couchdb/pull/2562
 
 
   Previously each doc was read in a separate transaction. It turns out that size
   limits do not apply to read-only transactions so we don't have to worry about
   that here. Also transaction restart are already implemented so we don't have to
   worry about timeout either.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb] nickva commented on issue #2562: Re-use changes feed main transaction when including docs

Posted by GitBox <gi...@apache.org>.
nickva commented on issue #2562: Re-use changes feed main transaction when including docs
URL: https://github.com/apache/couchdb/pull/2562#issuecomment-587490247
 
 
   @eiri good question. The changes feed will continue with the next db sequence. (Next key after the last emitted one in the changes key range). Between transaction a document which was already emitted could be updated. In that case a document could be emitted again in the same changes feed later on.
   
   It could be something like:
   ```
   {"seq": "1", "id":"doc1", ...}
   {"seq": "2": "id":"doc2", ...}
   Tx timeout
   doc1 updated
   {"seq": 3", "id":"doc3",...}
   {"seq", "4", "id":"doc1", ...}
   ```
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb] nickva merged pull request #2562: Re-use changes feed main transaction when including docs

Posted by GitBox <gi...@apache.org>.
nickva merged pull request #2562: Re-use changes feed main transaction when including docs
URL: https://github.com/apache/couchdb/pull/2562
 
 
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb] nickva commented on issue #2562: Re-use changes feed main transaction when including docs

Posted by GitBox <gi...@apache.org>.
nickva commented on issue #2562: Re-use changes feed main transaction when including docs
URL: https://github.com/apache/couchdb/pull/2562#issuecomment-587209856
 
 
   Benchmarking this vs prototype/fdb-layer get about a 2x speed up on macos with a single fdbserver with 1 million docs:
   
   prototype/fdb-layer
   ``` 
   $ time http $DB/deebee/_changes?include_docs=true > changes_1m_incude_docs.json_2.json
   
   real	7m58.086s
   user	0m4.157s
   sys	0m2.404s
   ```
   
   This PR:
   ```
   $ time http $DB/deebee/_changes?include_docs=true > changes_1m_incude_docs.json_3.json
   
   real	4m54.697s
   user	0m3.687s
   sys	0m2.200s
   ```
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb] eiri commented on issue #2562: Re-use changes feed main transaction when including docs

Posted by GitBox <gi...@apache.org>.
eiri commented on issue #2562: Re-use changes feed main transaction when including docs
URL: https://github.com/apache/couchdb/pull/2562#issuecomment-587471810
 
 
   just for my understanding, what'd happen if changes transaction times out and restarts, but db was updated in-between? will changes get the different result?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services