references in objects

Dustin Sallings dustin at
Fri Aug 10 09:03:51 UTC 2007

On Aug 10, 2007, at 1:13, Cam Bazz wrote:

> Consider the following scenario where I have an object:
> class Node {
>    int id;
>    Node next;
> }
> and I am storing these in memcached, such as:
> Node n;
> put(, n);
> when I get(int) a node, can I trace the reference next, without  
> requiring a map lookup?

	memcached is just a hash table.  For example:

	Map<Integer, Node> m=new HashMap<Integer, Node>();

	m.put(, n);

	Can you get in that example without doing another map lookup?

	Furthermore, it doesn't attempt to understand the data you're giving  
it.  The value is a blob and memcached can not and should not  
understand what it actually means.

Dustin Sallings

-------------- next part --------------
An HTML attachment was scrubbed...

More information about the memcached mailing list