java client locking issue
sgrimm at facebook.com
Thu Apr 5 01:09:16 UTC 2007
Dustin Sallings wrote:
> I was hoping to add UDP support to my client, but my preliminary
> testing was a bit disappointing since multi-packet requests were rejected.
Yes, that's a limitation of the current implementation, which was really
designed to handle reads rather than writes. The reasoning is that a
dropped request or response packet in a "get" request can simply be
treated as a cache miss and dealt with using a simple client-side
timeout, while a dropped packet on a "set" or "delete" or whatever would
need to be handled by a retransmission layer somewhere (essentially
reimplementing TCP in application-level code). Since our application
expects writes to be reliable, it didn't make much sense to put them on
an unreliable transport layer.
Also, handling multi-packet requests would make the server-side code
significantly more stateful and complex, and we wanted to keep the
server side as simple and short as possible to maximize performance.
Responses, of course, can span multiple packets.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the memcached