refactor the interface of memcache wraper