added memcache support to the lib