No, you can't solve this problem as long as you keep insisting on your
weird setup.

If you drop that repcached nonsense and instead use memcached like you're
supposed to, it will work perfectly, because a user's session will only
ever be on one memcached server, making all operations on that cached data
atomic.

If you absolutely must have some sort of replicated datastore, memcached is
the wrong choice, you'd be much better off looking at *actual* replicated
datastores, such as HBase or MongoDB.


/Henrik

On Wed, Oct 24, 2012 at 3:12 PM, Kiran Kumar <krn1...@gmail.com> wrote:

> I am using two instances of Memcache , both acting as Master Master(active
> active) nodes , so both are capable of reciving requests from User .
>
> Initially when the User logs in into the Application , he may go into any
> instance of the above  Memcahe (Either Server 1 Or server 2) and I am
> storing User Logged in Status into Memcache . ( So as per the Seetup right
> now this Status Might go into any one of the Memcache Instance )
>
>
> And as per my Application business rules ,  i cant allow a User to Login
> Multiple times .
>
> Please let me know how can i stop the already Logged in User from logging
> in twice in this scenario .
>
> I tried  Using MemcacheClient.cas opeartion , to solve this but
> unfortunately its comparing with only one instance of Memcache .
>
>
> And moreover even though repcached is set up on both instances of Memcache
> for replication purpose , but there is a slight delay in replication of
> Data between these servers
>
> Please let me know if there is anyway to solve this ??
>
> I am using Memcached 1.4.5 .
>
>

Reply via email to