Add memcache query caching (credit to @hpainter)

This is the memcache query caching support that @hpainter added
into our AR fork.  Porting it over from the framework version
into our fork.
Merge pull request #4 from getloaded/query-caching

Add memcache query caching (credit to @hpainter)