Yangsx-1 commented on code in PR #1490:
URL: 
https://github.com/apache/incubator-kvrocks/pull/1490#discussion_r1231902054


##########
src/commands/cmd_zset.cc:
##########
@@ -221,64 +223,217 @@ class CommandZLexCount : public Commander {
   RangeLexSpec spec_;
 };
 
-class CommandZPop : public Commander {
+class CommandZPop : public Commander,
+                    private EvbufCallbackBase<CommandZPop, false>,
+                    private EventCallbackBase<CommandZPop> {
  public:
-  explicit CommandZPop(bool min) : min_(min) {}
+  explicit CommandZPop(bool min, bool block) : min_(min), block_(block) {}

Review Comment:
   The differences between zpopmin/max and bzpopmin/max is that: 1.bzpopmin/max 
have an additional 'timeout' input parameter 2.bzpopmin/max have an additional 
'key' output. The inner processing logic is the same.
   In my first edition of the implementation, i implement the bzpopmin/max 
independent of zpopmin/max. But i received a comment that it has something 
duplicate. Maybe i misunderstood it. 
   But i think it's Ok? There are also some 'block' in the implementation of 
bzmpop and zmpop.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to