Multithreading use of XMemcached client


client = new XMemcachedClient(server, port);

What happens if I have several thread doing this:

object = client.get(key);

In the (quite empty) xmemcached javadoc I see no mention of synchronization.

  1. is MemcachedClient.get synchronized? if not, have I got to synchronize it myself?
  2. can calls to memcached be done in parallel, in order to avoid my threads to be blocked? Do I need to instanciate one MemcachedClient per thread or is the current code capable of this already?


XMemcachedClient can be used by many threads in paralel. There is not need to synchronize the calling to XMemcachedClient instance. Here's a sample code how many threads can use single client.

On the xmemcached page there's a benchmark which show performance depending on number of threads that use single XMemcachedClient instance.

Need Your Help

How can you iterate between a letter string on the text field of a button in ASP.NET/C# enviroment?

c# button browser

I have 9 buttons set up as a tic tac toe game. It is web browser based so for the two players to play, they must connect to the browser URL, and enter a que for a game. When they're in the game, the

Javascript library to generate workflow configuration diagrams

javascript workflow diagram

I have a set of predefined flow diagrams, and I need a way to display the diagram and allow the user to interactively set inputs and/or properties at various nodes in the diagram. The nodes/connec...