1) some libraries implement hash to stripe informations (like raid0 do
with disks), you should use deterministic hash function (always set
the key, to the same server)
2) failover should be a mirror flag (like raid1 with disks), it should
write to all servers that variable (write on all servers = write and
wait all servers to talk: that's ok), in case of a server problem, all
servers have the same information (you can use repcache, a memcache
similar server, with same memcache protocol and based on memcache, but
with replication feature, in this case replication is done in server,
not in client, check if it's a good sync time for you, and if it's a
network problem or not)
3) no, you can use UDP in a good network, it's faster (don't need
connection) and don't have a lot of latency (TCP can have latency, but
some options can reduce it) persistent connection remove the
connection time, but it's make another problem... the TCP list get
bigger, maybe you TCP list can overflow the operational system TCP
list, and some connections must be closed... UDP don't have this
problem, it's connectionless =)

2011/2/8 y1rm3y4hu <[email protected]>:
> Hi,
>
> I've been trying to find resources online to address a few questions i
> had regarding the various configuration options available with
> Memcached client/server without much success.
>
> Heres how my setup would look like
> i'd have two web servers [amazon EC2 instances] load balancing
> incoming requests in a round robin fashion - each of these web servers
> would have memcached[client and server] installed in it
>
> Now it would be great if somebody could give me pointers on the below
> questions.
>
> #1) Should i use consistent hashing.
> I am not expecting instances to go down randomly. But whenever one
> machine has to be taken out for maintenance etc, would like to
> minimize the impact. i read about a reduced performance when switched
> to consistent hashing. Not sure whether it is still valid.
>
> #2 ) If we are using standard vs consistent hashing how would failover
> work?
> I see that pecl/memcache has a failover flag but can't find anything
> similar to it in pecl/memcached. What are the implications.
>
> #3) Should i always go with persistent connections?
>
>
> Any help/links/pointers would be highly appreciated :)
>
>
> Have a good day
> y1rm3y4hu



-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial

Reply via email to