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

Memcached flags loses during load from snapshot #3134

Closed
sbkoto opened this issue Jun 5, 2024 · 2 comments
Closed

Memcached flags loses during load from snapshot #3134

sbkoto opened this issue Jun 5, 2024 · 2 comments
Assignees
Labels
bug Something isn't working Next Up task that is ready to be worked on and should be added to working queue

Comments

@sbkoto
Copy link

sbkoto commented Jun 5, 2024

not fixed on 1.19.0

set item 4 3600 4
test
STORED
get item
VALUE item 4 4
test
END

after reload dragonfly and load from snapshot:

get item
VALUE item 0 4
test
END

Originally posted by @sbkoto in #1758 (comment)

@romange romange added bug Something isn't working Next Up task that is ready to be worked on and should be added to working queue labels Aug 11, 2024
@romange
Copy link
Collaborator

romange commented Aug 11, 2024

definition of done - rdb_test reloads the snapshot file with mcflags.

@chakaz
Copy link
Collaborator

chakaz commented Aug 11, 2024

Thanks for filing this issue, @sbkoto. We plan to work on this soon.

Some more context:

  • memcached allows adding an integer flag to entries. In this case, the flag's value is 4
  • This type of flag metadata does not exist in Redis, so accessing it is only possible via the memcached API
  • We currently do not have support for this in rdb_save.cc and rdb_load.cc. We should add it, using a custom opcode (like we have for the STICKY bit today), because it's not supported nativly in RDB format
  • We do have support for this for stable sync. So a replica will accept changes for the flag. But it will not get the original value in full sync, for the same reason it is not saved to files.
  • IMHO, in addition to rdb_test, we should also add replication test to make sure this information is sent to replicas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Next Up task that is ready to be worked on and should be added to working queue
Projects
None yet
Development

No branches or pull requests

4 participants