Mongrel, memcache and sessions

Hi,

I’m using mongrel-0.3.13.3 with memcache-client-1.0.3 for storing
sessions.
It was working fine with actionpack-1.12.0, but when I upgraded to
actionpack-1.12.3, I started getting a “can’t convert String into Hash”
error from memcache.rb from memcache-client.

I was able to fix it by changing the way the MemCache object was created
in
actionpack/action_controller/session/ mem_cache_store.rb from:

     @cache = options['cache'] || MemCache.new('localhost')

to:
@cache = options[‘cache’] || MemCache.new()
@cache.servers = ‘localhost’

I’m not sure how this would affect the other Ruby-memcache library, but
thought this might
be helpful to anyone else trying to figure out this problem.

yours,
sness.

Hey Sness, can you try this with webrick to confirm it’s a Mongrel
problem? It looks like a MemCache issue really.

Hi Zed,

Great idea, thanks. I just tried it with webrick and confirmed that it
is a
memcache-client/actionpack issue.

yours,
sness.