-
Notifications
You must be signed in to change notification settings - Fork 1k
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
WIP Fixes(app): #1015 Command Migration: ('DEL', 'EXISTS', 'PERSIST', 'TYPE') #1146
Open
mohit-nagaraj
wants to merge
23
commits into
DiceDB:master
Choose a base branch
from
mohit-nagaraj:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mohit-nagaraj
changed the title
WIP Fixes(app): #1015 Command Migration: ('DEL', 'EXISTS', 'PERSIST', 'TYPE')
Fixes(app): #1015 Command Migration: ('DEL', 'EXISTS', 'PERSIST', 'TYPE')
Oct 19, 2024
Thanks for this PR. It looks like the CI is throwing some errors; please look into it. Additionally, please ensure the following checklist is part of your PR description and all items are checked off. At first glance, I can see that this PR does not add any new integration tests for the resp server.
|
Hey @JyotinderSingh I have asked few doubts in the orginal issue could you please help me out with it |
mohit-nagaraj
changed the title
Fixes(app): #1015 Command Migration: ('DEL', 'EXISTS', 'PERSIST', 'TYPE')
WIP Fixes(app): #1015 Command Migration: ('DEL', 'EXISTS', 'PERSIST', 'TYPE')
Oct 21, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Description for Issue #1015
Description:
This pull request addresses issue #1015 by migrating the 'DEL', 'EXISTS', 'PERSIST', and 'TYPE' commands to make them compatible across the three protocols supported by DiceDB: RESP, HTTP, and WebSocket. The current implementation of these commands is specific to the RESP protocol. The migration ensures protocol-agnostic behavior by refactoring the evaluation functions to return raw responses instead of protocol-specific responses.
Changes Made:
Refactored Evaluation Functions:
internal/eval/store_eval.go
.errors/migrated_errors.go
and predefined responses frominternal/clientio/resp.go
.Command/Worker Specific Changes:
IsMigrated
flag to true in the command information underinternal/eval/commands.go
.NewEval
parameter in the command structure.internal/eval/eval.go
.CommandsMeta
map ininternal/worker/CommandsMeta
with the typeSingleShard
.Unit and Integration Tests:
Checklist:
Additional Notes:
Related Issues/PRs:
This pull request ensures the command logic is protocol-independent, allowing all three protocols to call the same core functionality seamlessly.