<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/tooz.git/tooz/drivers/redis.py, branch master</title>
<subtitle>opendev.org: openstack/tooz.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/'/>
<entry>
<title>Enable retries in redis driver</title>
<updated>2021-06-16T16:44:38+00:00</updated>
<author>
<name>Pavlo Shchelokovskyy</name>
<email>shchelokovskyy@gmail.com</email>
</author>
<published>2021-06-10T13:32:32+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=47c4d56e446a49726e7145c6cbc3bb7620a431f7'/>
<id>47c4d56e446a49726e7145c6cbc3bb7620a431f7</id>
<content type='text'>
this is followup to Iaab5ce609c0dcf7085f5dd43efbd37eb4b88f17b

actually retry for specified number of retries instead of raising
error on first ConnectionError

Change-Id: Ibca3f568b65dfea252da4b67f6d5105ba7f1ecb1
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
this is followup to Iaab5ce609c0dcf7085f5dd43efbd37eb4b88f17b

actually retry for specified number of retries instead of raising
error on first ConnectionError

Change-Id: Ibca3f568b65dfea252da4b67f6d5105ba7f1ecb1
</pre>
</div>
</content>
</entry>
<entry>
<title>Retry on redis connection errors</title>
<updated>2021-03-31T08:49:35+00:00</updated>
<author>
<name>Matthias Runge</name>
<email>mrunge@redhat.com</email>
</author>
<published>2021-03-05T10:24:25+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=a025b4d4ee9fe1bd722960ea03445034580bec6f'/>
<id>a025b4d4ee9fe1bd722960ea03445034580bec6f</id>
<content type='text'>
Sometimes, connections get closed by the server. This change
adds retrying to the code.

Change-Id: Iaab5ce609c0dcf7085f5dd43efbd37eb4b88f17b
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sometimes, connections get closed by the server. This change
adds retrying to the code.

Change-Id: Iaab5ce609c0dcf7085f5dd43efbd37eb4b88f17b
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove six library</title>
<updated>2020-07-01T13:56:53+00:00</updated>
<author>
<name>Riccardo Pittau</name>
<email>elfosardo@gmail.com</email>
</author>
<published>2020-07-01T13:22:44+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=5ac72fcb3d2071d8fd4c382a48efe5b9dbd4dec9'/>
<id>5ac72fcb3d2071d8fd4c382a48efe5b9dbd4dec9</id>
<content type='text'>
The tooz project doesn't support Python 2 anymore, using the
six library should not be necessary.

Change-Id: I9886cabcd13cbc615065ceb372efbf037dff1aeb
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The tooz project doesn't support Python 2 anymore, using the
six library should not be necessary.

Change-Id: I9886cabcd13cbc615065ceb372efbf037dff1aeb
</pre>
</div>
</content>
</entry>
<entry>
<title>Stop to use the __future__ module.</title>
<updated>2020-06-02T19:02:18+00:00</updated>
<author>
<name>Hervé Beraud</name>
<email>hberaud@redhat.com</email>
</author>
<published>2020-06-02T19:02:18+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=9c4f23a01923563d43b2ddf5048340cc386e2c33'/>
<id>9c4f23a01923563d43b2ddf5048340cc386e2c33</id>
<content type='text'>
The __future__ module [1] was used in this context to ensure compatibility
between python 2 and python 3.

We previously dropped the support of python 2.7 [2] and now we only support
python 3 so we don't need to continue to use this module and the imports
listed below.

Imports commonly used and their related PEPs:
- `division` is related to PEP 238 [3]
- `print_function` is related to PEP 3105 [4]
- `unicode_literals` is related to PEP 3112 [5]
- `with_statement` is related to PEP 343 [6]
- `absolute_import` is related to PEP 328 [7]

[1] https://docs.python.org/3/library/__future__.html
[2] https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html
[3] https://www.python.org/dev/peps/pep-0238
[4] https://www.python.org/dev/peps/pep-3105
[5] https://www.python.org/dev/peps/pep-3112
[6] https://www.python.org/dev/peps/pep-0343
[7] https://www.python.org/dev/peps/pep-0328

Change-Id: I95809cf4035a6bc487b24f9e91aaa715921ad842
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The __future__ module [1] was used in this context to ensure compatibility
between python 2 and python 3.

We previously dropped the support of python 2.7 [2] and now we only support
python 3 so we don't need to continue to use this module and the imports
listed below.

Imports commonly used and their related PEPs:
- `division` is related to PEP 238 [3]
- `print_function` is related to PEP 3105 [4]
- `unicode_literals` is related to PEP 3112 [5]
- `with_statement` is related to PEP 343 [6]
- `absolute_import` is related to PEP 328 [7]

[1] https://docs.python.org/3/library/__future__.html
[2] https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html
[3] https://www.python.org/dev/peps/pep-0238
[4] https://www.python.org/dev/peps/pep-3105
[5] https://www.python.org/dev/peps/pep-3112
[6] https://www.python.org/dev/peps/pep-0343
[7] https://www.python.org/dev/peps/pep-0328

Change-Id: I95809cf4035a6bc487b24f9e91aaa715921ad842
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Avoid redis lock's expire_time exceeding timeout."</title>
<updated>2020-03-02T11:26:47+00:00</updated>
<author>
<name>Zuul</name>
<email>zuul@review.opendev.org</email>
</author>
<published>2020-03-02T11:26:47+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=27c4f158e5571c20069fc72d0b40a303da8149b2'/>
<id>27c4f158e5571c20069fc72d0b40a303da8149b2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>RedisLock release() should not check if the lock has been acquired</title>
<updated>2019-12-19T09:12:28+00:00</updated>
<author>
<name>Bob.Haddleton</name>
<email>bob.haddleton@nokia.com</email>
</author>
<published>2019-02-10T03:24:54+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=842c7404b2d01c5dd718c14bb55f0cd47471f0e1'/>
<id>842c7404b2d01c5dd718c14bb55f0cd47471f0e1</id>
<content type='text'>
The RedisDriver coordinator _stop() method removes the lock from the
_acquired_locks set before calling the release() method on the lock,
so the release() method should not check to see if the lock is in the
set, since it never will be.

This was preventing the coordinator's _stop() method from releasing
the locks, so they had to timeout before another group member could
take over as leader.

Change-Id: Ie23d88f1a05983d7465f18a329cabc23d789a628
Closes-Bug: 1815330
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The RedisDriver coordinator _stop() method removes the lock from the
_acquired_locks set before calling the release() method on the lock,
so the release() method should not check to see if the lock is in the
set, since it never will be.

This was preventing the coordinator's _stop() method from releasing
the locks, so they had to timeout before another group member could
take over as leader.

Change-Id: Ie23d88f1a05983d7465f18a329cabc23d789a628
Closes-Bug: 1815330
</pre>
</div>
</content>
</entry>
<entry>
<title>Avoid redis lock's expire_time exceeding timeout.</title>
<updated>2019-06-01T01:19:03+00:00</updated>
<author>
<name>garenchan</name>
<email>garenchan23@gmail.com</email>
</author>
<published>2019-04-03T13:58:56+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=20bda6ed999e71823b6eac90f01d1a29898b63b2'/>
<id>20bda6ed999e71823b6eac90f01d1a29898b63b2</id>
<content type='text'>
After n heartbeats, the expireation time of the lock key becomes
(1 + 0.5n) * timeout! Therefore, when the lock holder performs a
long task and exits abnormally, the lock will not be automatically
released in time.

Change-Id: I2437071bb575e95083b0d57a6a0a33aaf8356113
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
After n heartbeats, the expireation time of the lock key becomes
(1 + 0.5n) * timeout! Therefore, when the lock holder performs a
long task and exits abnormally, the lock will not be automatically
released in time.

Change-Id: I2437071bb575e95083b0d57a6a0a33aaf8356113
</pre>
</div>
</content>
</entry>
<entry>
<title>More explicitly document driver connection strings</title>
<updated>2018-12-17T22:37:55+00:00</updated>
<author>
<name>Ben Nemec</name>
<email>bnemec@redhat.com</email>
</author>
<published>2018-12-10T23:43:28+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=e76235b675f7816e79128446236eac81f5a6ec0a'/>
<id>e76235b675f7816e79128446236eac81f5a6ec0a</id>
<content type='text'>
If you're not intimately familiar with RFC 1808 it can be a bit tricky to
write tooz connection strings. In addition, some drivers do not document the
options that they recognize in a connection string. This can force a user to
read the driver code in order to figure out how to configure tooz to use said
driver, which should not be the case.

This change more explicitly documents the format of the connection string,
including which parts of an RFC 1808 URI it recognizes, and the options that
can be passed. It also clarifies which parts of the connection string are
optional (possibly because they have defaults) and which must always be
included.

Note that not every possible configuration is documented. For example, the
postgres driver supports multiple methods of configuring the connection host
and port. For consistency, I only documented the one that matches the other
drivers. This should be sufficient to allow a user to write a working
connection string.

This change also wires the etcd3 and etcd3gw drivers into the doc index since
they were missing before.

Change-Id: I66e54433115f27fb54badc2173f8f6044c49aacb
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If you're not intimately familiar with RFC 1808 it can be a bit tricky to
write tooz connection strings. In addition, some drivers do not document the
options that they recognize in a connection string. This can force a user to
read the driver code in order to figure out how to configure tooz to use said
driver, which should not be the case.

This change more explicitly documents the format of the connection string,
including which parts of an RFC 1808 URI it recognizes, and the options that
can be passed. It also clarifies which parts of the connection string are
optional (possibly because they have defaults) and which must always be
included.

Note that not every possible configuration is documented. For example, the
postgres driver supports multiple methods of configuring the connection host
and port. For consistency, I only documented the one that matches the other
drivers. This should be sufficient to allow a user to write a working
connection string.

This change also wires the etcd3 and etcd3gw drivers into the doc index since
they were missing before.

Change-Id: I66e54433115f27fb54badc2173f8f6044c49aacb
</pre>
</div>
</content>
</entry>
<entry>
<title>redis: always remove lock from acquired lock when release()ing</title>
<updated>2017-08-14T08:18:09+00:00</updated>
<author>
<name>Julien Danjou</name>
<email>julien@danjou.info</email>
</author>
<published>2017-08-14T08:18:09+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=3f25d41182a26e522a9805a17729295777a89728'/>
<id>3f25d41182a26e522a9805a17729295777a89728</id>
<content type='text'>
The failure scenarios where LockError is raised is either:
- Lock is not locked. Then it should not be in _acquired_locks, so discard
  should be a no-op.
- Token changed. That can happen if the lock timed-out (and somebody else
  grabbed it). Then the lock is not longer owned anyway so let's remove it.

If releasing the lock fails, there's no way heartbeat will work anyway. So just
remove the lock from acquired locks and let it die anyway.

Change-Id: I44db39e83db7e6c0f17079584e49c8de34b51ce1
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The failure scenarios where LockError is raised is either:
- Lock is not locked. Then it should not be in _acquired_locks, so discard
  should be a no-op.
- Token changed. That can happen if the lock timed-out (and somebody else
  grabbed it). Then the lock is not longer owned anyway so let's remove it.

If releasing the lock fails, there's no way heartbeat will work anyway. So just
remove the lock from acquired locks and let it die anyway.

Change-Id: I44db39e83db7e6c0f17079584e49c8de34b51ce1
</pre>
</div>
</content>
</entry>
<entry>
<title>redis: log an error on release failure</title>
<updated>2017-08-14T08:17:20+00:00</updated>
<author>
<name>Julien Danjou</name>
<email>julien@danjou.info</email>
</author>
<published>2017-08-14T08:17:20+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/tooz.git/commit/?id=a25815d9a89e990c16d40b8312b6772937f2975c'/>
<id>a25815d9a89e990c16d40b8312b6772937f2975c</id>
<content type='text'>
Change-Id: Id63beaea3a0bc972a7117526aee1ad3f1ac99d84
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: Id63beaea3a0bc972a7117526aee1ad3f1ac99d84
</pre>
</div>
</content>
</entry>
</feed>
