| 
	
 | 
 Posted by Erwin Moller on 03/16/07 08:16 
surfivor wrote: 
 
>  
>  I understand that memcached can store objects on different servers 
> using hashing, and I've seen typical things such as storing query 
> results. 
>  
> Say at line 100 in module 'A', I want to render some content so I 
> check the memcache. If previously I had rendered this from this same 
> line of code and it's in the cache, then I use that. However, what if 
> module B changed one of the records on the database and that was in 
> the cache ? It must be up to me to have a scheme worked out that I 
> will delete the object from the cache that is referenced from module A 
> because I changed the database. 
 
Hi, 
 
Sorry if I sound stupid because I never worked with memcache, BUT isn't this  
excactly the kind of thing where you need a database? 
A database will handle your concurrency, possible changed tuples, etc just  
fine. 
 
You can even store the results of a query in the database if you want, and  
just update that when needed (= when the underlying data changes). 
 
Regards, 
Erwin Moller
 
  
Navigation:
[Reply to this message] 
 |