headius/jruby-spymemcached — Issue #1: Drop-in compatibility with memcache-client/jruby-memcache-client
Author: LeifWarner
Created: 2012-02-21 22:25:40+00:00
State: open

There are some methods / signatures missing if this is to be a drop-in replacement.

I made a wrapper object to log method calls to SESSION_CACHE:
https://gist.github.com/1879156

The next thing after the `[http-bio-3000-exec-1] Added Cmd: get Keys: session:c9b5edfc51a5a21b4138872948c6c6d6 Exp: 0 to {QA sa=/127.0.0.1:11211, #Rops=0, #Wops=0, #iq=0, topRop=null, topWop=null, toWrite=0, interested=0}` in the log is an `ERROR` of that giant stacktrace I posted before, from that same [http-bio-3000-exec-1] thread.

For comparison, when using https://github.com/ikai/jruby-memcache-client, the method calls are:

:get
[
[0] "session:c9b5edfc51a5a21b4138872948c6c6d6"
]
:add
[
[0] "session:c9b5edfc51a5a21b4138872948c6c6d6",
[1] {},
[2] 0
]
:[]
[
[0] "session:c9b5edfc51a5a21b4138872948c6c6d6"
]
instead of two :get's and a stacktrace.

Another thing of the legacy API we have in the codebase is the "raw" option to .get, seen here:
https://github.com/ikai/jruby-memcache-client/blob/master/lib/memcache.rb#L179