<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/couchdb.git/src/ioq, branch decrease-indexer-transaction-time-limit</title>
<subtitle>github.com: apache/couchdb.git
</subtitle>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/couchdb.git/'/>
<entry>
<title>fix: set gen_server:call() timeout to infinity on ioq bypass</title>
<updated>2020-07-03T16:32:08+00:00</updated>
<author>
<name>Jan Lehnardt</name>
<email>jan@apache.org</email>
</author>
<published>2020-07-02T19:06:24+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/couchdb.git/commit/?id=0eedd8bcd4f7d2a86d5caded3a0bc0a963c24dc7'/>
<id>0eedd8bcd4f7d2a86d5caded3a0bc0a963c24dc7</id>
<content type='text'>
Before the bypass existed, ioq would call `gen_server:call()`
on hehalf of it calling module with the queueing logic in between.

Commit e641a740 introduced a way to bypass any queues, but the
delegated `gen_server:call()` there was added without a timeout
parameter, leading to a default timeout of 5000ms.

A problem manifests here when operations that are sent through
ioq that take longer than that 5000ms timeout. In practice, these
operations should be very rare and this timeout should be a help
on overloaded systems. However, one sure-fire way to cause an issue
on an otherwise idle machine is raise the max_document_size and
store unreasonably large documents, think 50MB+ of raw JSON).

Not that we recommend this, but folks have run this fine on 2.x
before the ioq changes and it isn’t too hard to support here.

By adding an `infinity` timeout delegated `gen_server:call()` in
the queue bypasse case, this no longer applies.

Thanks to Joan @woahli Touzet, Bob @rnewson Newson and
Paul @davisp Davis for helping to track this down.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Before the bypass existed, ioq would call `gen_server:call()`
on hehalf of it calling module with the queueing logic in between.

Commit e641a740 introduced a way to bypass any queues, but the
delegated `gen_server:call()` there was added without a timeout
parameter, leading to a default timeout of 5000ms.

A problem manifests here when operations that are sent through
ioq that take longer than that 5000ms timeout. In practice, these
operations should be very rare and this timeout should be a help
on overloaded systems. However, one sure-fire way to cause an issue
on an otherwise idle machine is raise the max_document_size and
store unreasonably large documents, think 50MB+ of raw JSON).

Not that we recommend this, but folks have run this fine on 2.x
before the ioq changes and it isn’t too hard to support here.

By adding an `infinity` timeout delegated `gen_server:call()` in
the queue bypasse case, this no longer applies.

Thanks to Joan @woahli Touzet, Bob @rnewson Newson and
Paul @davisp Davis for helping to track this down.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add 'src/ioq/' from commit 'e641a740978447f0b29785580e46d2e30e822001'</title>
<updated>2020-01-06T19:41:33+00:00</updated>
<author>
<name>Adam Kocoloski</name>
<email>kocolosk@apache.org</email>
</author>
<published>2020-01-06T19:41:33+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/couchdb.git/commit/?id=53d3d8febe3a1d0a27cdc9bf77f6bf5fc6513e56'/>
<id>53d3d8febe3a1d0a27cdc9bf77f6bf5fc6513e56</id>
<content type='text'>
git-subtree-dir: src/ioq
git-subtree-mainline: c8a5757c33c8f782d935fce2f804cb745bf77b4a
git-subtree-split: e641a740978447f0b29785580e46d2e30e822001
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-subtree-dir: src/ioq
git-subtree-mainline: c8a5757c33c8f782d935fce2f804cb745bf77b4a
git-subtree-split: e641a740978447f0b29785580e46d2e30e822001
</pre>
</div>
</content>
</entry>
</feed>
