jihuayu commented on code in PR #2055:
URL: https://github.com/apache/kvrocks/pull/2055#discussion_r1467390044
##########
src/commands/commander.h:
##########
@@ -93,18 +93,22 @@ class CommanderWithParseMove : Commander {
using CommanderFactory = std::function<std::unique_ptr<Commander>()>;
struct CommandKeyRange {
- // index of the first key in command tokens
+ // index of the first key (non-store key) in command tokens
// 0 stands for no key, since the first index of command arguments is
command name
int first_key;
- // index of the last key in command tokens
+ // index of the last key (non-store key) in command tokens
// in normal one-key commands, first key and last key index are both 1
// -n stands for the n-th last index of the sequence, i.e. args.size() - n
int last_key;
- // step length of key position
+ // step length of key (non-store key) position
// e.g. key step 2 means "key other key other ..." sequence
int key_step;
+
+ // index of the store key in command tokens
+ // 0 stands for no store key, since the first index of command arguments is
command name
+ int store_key;
Review Comment:
If I'm a new developer, I'm not quite sure what this variable is used for.
When do I need to set this variable?
Could you please add some comments to clarify?
--
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]