Skip to content

Support namespaces on CAS operations#309

Open
fangel wants to merge 2 commits into3rd-Eden:masterfrom
tv2:feature/support-namespaces-on-cas
Open

Support namespaces on CAS operations#309
fangel wants to merge 2 commits into3rd-Eden:masterfrom
tv2:feature/support-namespaces-on-cas

Conversation

@fangel
Copy link
Copy Markdown

@fangel fangel commented May 24, 2017

I was doing some work on atomic updates to Memcache using CAS, and ran it an issue when you have namespaces enabled in your Memcached-client: The namespace would still be present in the object that is returned.

So when you have a namespace foo: and do a client.gets('bar', function(err, res) { ... }) then the response-object contains {cas: ?, 'foo:bar': ?} instead of the expected {cas: ?, bar: ?}.

I've updated the namespace tests to also included a successful CAS-write with a namespace and added a handle-function to the gets-function that strips the namespace off of the full key.

Kind regards
Morten

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.

1 participant