From b9f49c38f11965727d32f41e4a5b802f72fb60f6 Mon Sep 17 00:00:00 2001 From: Andy McCurdy Date: Tue, 28 May 2019 14:14:40 -0700 Subject: cleanup MONITOR docs --- CHANGES | 2 ++ README.rst | 14 +++++++------- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/CHANGES b/CHANGES index a3d98f5..a6bc061 100644 --- a/CHANGES +++ b/CHANGES @@ -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 diff --git a/README.rst b/README.rst index 01551fa..8ea31b8 100644 --- a/README.rst +++ b/README.rst @@ -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 ^^^^^^^^^^^^^ -- cgit v1.2.1