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

Add support for raw data flag #131

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rkday
Copy link

@rkday rkday commented Jun 22, 2018

Hi,

I'm using python-binary-memcached to help test an application which already uses the 'opaque' field in memcached - which means that sometimes the right bit is set for python-binary-memcached to incorrectly interpret my data as compressed data or an integer, and fail to parse it.

This adds a raw_data flag, which maks it skip serialisation and deserialisation and just treat the data as binary.


This change is Reviewable

@jaysonsantos
Copy link
Owner

Hey @rkday sorry for the long delay. I am mostly trying to maintain compatibility with the other libraries. Do you know what is the expected behavior for this in pylibmc for example? One suggestion is to run the dogpile cache's tests using your branch and see how it behaves, it has been a good way to check if compatibility is not broken.

@rkday
Copy link
Author

rkday commented Jul 10, 2018

In pylibmc the Client class can be subclassed to override the serialize and deserialize methods (http://sendapatch.se/projects/pylibmc/reference.html#pylibmc.Client.serialize) - maybe that would be a better way to do what I want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants