dice icon indicating copy to clipboard operation
dice copied to clipboard

Add support for `PX` in `SET` command

Open arpitbbhayani opened this issue 1 year ago • 4 comments

We already have the SET command implemented. Now we need to add support for PX option similar to the PX option in Redis. Please refer to the following commit in Redis to understand the implementation specifics - source.

Write unit and integration tests for the command referring to the tests written in the Redis codebase 7.2.5. For integration tests, you can refer to the tests folder. Note: they have used TCL for the test suite, and we need to port that to our way of writing integration tests using the relevant helper methods. Please refer to our tests directory.

For the command, benchmark the code and measure the time taken and memory allocs using benchmem and try to keep them to the bare minimum.

arpitbbhayani avatar Aug 02 '24 14:08 arpitbbhayani

Hey @arpitbbhayani , I would like to take this up.

SyedMa3 avatar Aug 02 '24 14:08 SyedMa3

@SyedMa3 Assigned the issue to you. Go for it.

It would be awesome if you keep posting updates to this issue so that we know you are working on it. If we see an inactivity of 7 days, we will remove your assignment. This is just to ensure that the project maintains its momentum and others are not blocked on this work.

But it really means a ton to us that you are contributing to this project. Thanks again.

arpitbbhayani avatar Aug 02 '24 15:08 arpitbbhayani

Sure, understandable.

SyedMa3 avatar Aug 02 '24 19:08 SyedMa3

completed the task. Waiting for Issue 213 to get resolved.

Side Note: The benchmark cli command for evalSET needs to have the value of benchtime flag less than 100x since WatchChannel is a buffered channel of size 100 and may lead to a deadlock.

SyedMa3 avatar Aug 02 '24 22:08 SyedMa3

https://github.com/DiceDB/dice/pull/236/

arpitbbhayani avatar Aug 05 '24 18:08 arpitbbhayani