Application (memcached client) can not continue to use thememcached instances after a memcached restart ... (theapplication itself is not restarted)

a. a at
Thu Jan 10 23:54:55 UTC 2008


I'm the author of the client you're using.

When the service is restarted all connections in the pool become  
invalid, so next time you try to do something with memcached the  
client will fail. This exception should be hidden though and the  
server should be marked as "dead" for a (configurable) period of time.  
So probably this exception is not hidden enough and you're hitting a  
bug :)

Please send me the stack trace of the exception and i'll look into it.  
In the meanwhile you might wanna try out the latest version of the  
client (available in source on codeplex)



On Jan 11, 2008, at 12:29 AM, Kiran Bhogadi wrote:

> Hello folks!
> I am playing around with memcached and I have a question based on  
> the following scenario.
> Before I describe my scenario, here's the info on my setup:
> i)  memcached 1.2.1 on Windows XP
> ii) Using a C# Memcached Client (Enyim.Caching)
> Here's a simplified scenario for the sake of description ...
> 1) App A is configured to use memcached instances M1, M2.
> 2) App A is started and it starts storing/getting objects to/from  
> memcached. Then App A takes a little break from using memcached :)
> 3) Memcached instances M1, M2 are stopped and re-started, while app  
> A continues to run.
> 4) The next time App A tries to use the restarted memcached (M1 or  
> M2) there is an error/exception.
> 5) If I stop and start (i.e., restart) App A itself, then it works  
> okay again with memcached instances M1 and M2.
> My concern is with (4) above.
> Is (4) just an artifact of the client API we are using that App A   
> fails to use memcached instances after the memcached restart?  
> (Perhaps, someone using Enyim.Caching C# API can answer this - maybe  
> there is a way to configure the client so that it won't fail during  
> (4)?) I am looking into the Enyim.Caching   code to see what I need  
> to change in order to change the behavior seen in (4). But I am  
> hoping there may be a solution already out there for this ...  :)
> Any helpful ideas on this issue [even if you are using a different  
> type of memcached client] are appreciated.
> Best Regards,
> Kiran

More information about the memcached mailing list