Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented PSETEX command #207

Merged
merged 3 commits into from
Aug 31, 2022

Conversation

Valkyrie00
Copy link
Collaborator

No description provided.

@codecov
Copy link

codecov bot commented Aug 31, 2022

Codecov Report

Base: 80.31% // Head: 80.33% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (24fe1bc) compared to base (46ec103).
Patch coverage: 89.47% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #207      +/-   ##
==========================================
+ Coverage   80.31%   80.33%   +0.02%     
==========================================
  Files         132      133       +1     
  Lines        7993     8012      +19     
==========================================
+ Hits         6419     6436      +17     
- Misses       1574     1576       +2     
Impacted Files Coverage Δ
...module/redis/command/module_redis_command_psetex.c 89.47% <89.47%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Owner

@danielealbano danielealbano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As for the SETEX command, just an additional check oh the value passed by the user is needed and nothing else

bool return_res = false;
bool key_and_value_owned = false;
module_redis_command_psetex_context_t *context = connection_context->command.context;

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a check to valiate that the value passed in greater than 0, if not the following error has to be returned

ERR invalid expire time in 'psetex' command

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done 👍

@danielealbano danielealbano added the enhancement New feature or request label Aug 31, 2022
@danielealbano danielealbano added this to the v0.2 milestone Aug 31, 2022
@danielealbano danielealbano merged commit 42dcc3e into danielealbano:main Aug 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants