[jifty-devel] Using Jifty::Config::postload to override config during testing

Jesse Vincent jesse at bestpractical.com
Fri Jun 2 12:06:02 EDT 2006

> I just committed two tests that are identical other then that one uses a
> RecordBaseClass of Jifty::DBI::Record (and does what I'd expect) and one
> uses a RecordBaseClass of Jifty::DBI::Record::Cachable and differs in
> behavior from the first test.  I would have expected that the cache
> would have been invalidated on an update and that the updated record
> would be returned on a new load but that does not seem to be the case.
> Hopefully, this will be obvious to someone more familiar with
> Jifty::DBI's caching.  If not I will try to find some time to look at it
> in more detail sometime soon.

Yep! The problem is that Jifty::DBI::Record::Cachable is a
single-process cache. And the updates you're making are in a second
process. So the only way to see the updates is to wait until the cache
clears _or_ to manually clear it.  If you were using
Jifty::DBI::Record::MemCached, this wouldn't be an issue.

> Sean
> -- 
>  Sean E. Millichamp, Enertron LLC, 586-757-1200 x102
> _______________________________________________
> jifty-devel mailing list
> jifty-devel at lists.jifty.org
> http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel


More information about the jifty-devel mailing list