You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kvrocks.apache.org by "infdahai (via GitHub)" <gi...@apache.org> on 2023/05/24 05:02:51 UTC

[GitHub] [incubator-kvrocks] infdahai opened a new issue, #1469: Add parser functions to `Set`

infdahai opened a new issue, #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469

   ### Search before asking
   
   - [X] I had searched in the [issues](https://github.com/apache/incubator-kvrocks/issues) and found no similar issues.
   
   
   ### Motivation
   
   Many commands in the current [`cmd_set`](https://github.com/apache/incubator-kvrocks/blob/b9cfbead58f68aa914bb35360f82c3f8e0ec8c90/src/commands/cmd_set.cc) file miss parsing functions.
   
   For example,
   https://github.com/apache/incubator-kvrocks/blob/b9cfbead58f68aa914bb35360f82c3f8e0ec8c90/src/commands/cmd_set.cc#L211-L224
   
   ### Solution
   
   Add parse() functions to their classes.
   
   ### Are you willing to submit a PR?
   
   - [X] I'm willing to submit a PR!


-- 
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: issues-unsubscribe@kvrocks.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] infdahai closed issue #1469: Add parser functions to `Set`

Posted by "infdahai (via GitHub)" <gi...@apache.org>.
infdahai closed issue #1469: Add parser functions to `Set` 
URL: https://github.com/apache/incubator-kvrocks/issues/1469


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] zncleon commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "zncleon (via GitHub)" <gi...@apache.org>.
zncleon commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562702247

   I have some questions:
   1. In redis6.9, if I enter "SPOP myset 3.5" OR "SPOP myset -10", it return "value is out of range, must be positive", but in kvrocks, it return "value is not a n integer out of range ".It seems that the return in kvrocks is clearer. Should I modify it just like redis or leave it as it is ?  
   
   2. if I enter "SPOP myset 3 4", the arguments more than 3, kvrocks not return error. I can modify the checks in source code. But I can't test it in go test, for the arguments num of the function "SPopN" is 3. How can I do ?  


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] zncleon commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "zncleon (via GitHub)" <gi...@apache.org>.
zncleon commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562358297

   I'd like to try it


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] git-hulk commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "git-hulk (via GitHub)" <gi...@apache.org>.
git-hulk commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562706807

   > In redis6.9, if I enter "SPOP myset 3.5" OR "SPOP myset -10", it return "value is out of range, must be positive", but in kvrocks, it return "value is not a n integer out of range ".It seems that the return in kvrocks is clearer. Should I modify it just like redis or leave it as it is ?
   
   Just leave it as it's.
   
   > if I enter "SPOP myset 3 4", the arguments more than 3, kvrocks not return error. I can modify the checks in source code. But I can't test it in go test, for the arguments num of the function "SPopN" is 3. How can I do ?
   
   You can use `client.Do` to send the raw command.


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] infdahai commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "infdahai (via GitHub)" <gi...@apache.org>.
infdahai commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1560520746

   This issue just needs to add `require.Error()` in go tests. If someone is willing to do this, leave a message here.


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] infdahai commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "infdahai (via GitHub)" <gi...@apache.org>.
infdahai commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562857056

   You can add a go test for computing results and a go test for getting error msgs to coverege the throwing errors  for the second label


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] git-hulk commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "git-hulk (via GitHub)" <gi...@apache.org>.
git-hulk commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562365938

   @zncleon Assigned, go ahead. @infdahai Thanks for taking care of this PR.


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] infdahai commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "infdahai (via GitHub)" <gi...@apache.org>.
infdahai commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562867837

   you can add a go test if you want to comoute the commands and add another test for parsing error msgs.(usually use Do func, because go-redis gives a correct num-key argument.)


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] git-hulk closed issue #1469: Refine functions and add parsing tests to `Set`

Posted by "git-hulk (via GitHub)" <gi...@apache.org>.
git-hulk closed issue #1469: Refine functions and add parsing tests to `Set` 
URL: https://github.com/apache/incubator-kvrocks/issues/1469


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] infdahai commented on issue #1469: Add parser functions to `Set`

Posted by "infdahai (via GitHub)" <gi...@apache.org>.
infdahai commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1560461896

   Please add a `good first issue` label.


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-kvrocks] zncleon commented on issue #1469: Refine functions and add parsing tests to `Set`

Posted by "zncleon (via GitHub)" <gi...@apache.org>.
zncleon commented on issue #1469:
URL: https://github.com/apache/incubator-kvrocks/issues/1469#issuecomment-1562890622

   thx !
   


-- 
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: issues-unsubscribe@kvrocks.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org