Why are you trying to do this? That's generally a bad sign, the
replication is for redundancy. if you're just trying to confirm it works,
you can do a brute force search for the key

On Thu, 2 Aug 2018, Om Kale wrote:

> Hi All,I have enabled replication (using --NUMBER_OF_REPLICAS) and ketama 
> hashing.
> This means, I will have replicas of keys stored on different servers 
> memntioned in my server list.
>
> My question is, is there any way of retrieving the list of servers where 
> replicas of a particular key lie, in libmemcached?
> Example: If I give a key, I need all the servers where replicas of that key 
> are stored.
>
> For getting one server where key is stored, I use this:
> const struct memcached_instance_st *server;server = const 
> memcached_instance_st * memcached_server_by_key(memcached_st *ptr, const
> char *key, size_t key_length, memcached_return_t *error);
>
>
>   However, I am unable to print the hostname from the returned structure 
> using server->hostname
>
>   in a .c file. Can this info not be printed?
>
> Thanks and Regards,
>
> Om Kale
>
>
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups 
> "memcached" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to memcached+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"memcached" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to memcached+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to