diff options
author | Andy McCurdy <andy@andymccurdy.com> | 2019-05-28 14:14:40 -0700 |
---|---|---|
committer | Andy McCurdy <andy@andymccurdy.com> | 2019-05-28 14:14:40 -0700 |
commit | b9f49c38f11965727d32f41e4a5b802f72fb60f6 (patch) | |
tree | b6d2ac1d82225a1673d17ea1366cf07bc159836a | |
parent | 4986b5541e804257bee108908c2184d8ec6dd79c (diff) | |
download | redis-py-b9f49c38f11965727d32f41e4a5b802f72fb60f6.tar.gz |
cleanup MONITOR docs
-rw-r--r-- | CHANGES | 2 | ||||
-rw-r--r-- | README.rst | 14 |
2 files changed, 9 insertions, 7 deletions
@@ -2,6 +2,8 @@ * Resolve a race condition with the PubSubWorkerThread. #1150 * Cleanup socket read error messages. Thanks Vic Yu. #1159 * Cleanup the Connection's selector correctly. Thanks Bruce Merry. #1153 + * Added a Monitor object to make working with MONITOR output easy. + Thanks Roey Prat #1033 * 3.2.1 * Fix SentinelConnectionPool to work in multiprocess/forked environments. * 3.2.0 @@ -677,16 +677,16 @@ supported: Monitor ^^^^^^^ -redis-py includes a `Monitor` object that that streams back every command -processed by the Redis server. Use `listen` on the `Monitor` object to block -until message available. +redis-py includes a `Monitor` object that streams every command processed +by the Redis server. Use `listen()` on the `Monitor` object to block +until a command is received. .. code-block:: pycon - >>> r = redis.StrictRedis(...) - >>> with sr.monitor() as m: - >>> for command in m.listen(): - >>> print(command) + >>> r = redis.Redis(...) + >>> with r.monitor() as m: + >>> for command in m.listen(): + >>> print(command) Lua Scripting ^^^^^^^^^^^^^ |