add batch writes in cache.

In this PR, batch writes is added to the in memory cache as mentioned in #182
I'm considering to add a method to the StorageDriver interface. How about this: Add a private method called ``flushUnsafe()`` which flush data without locking; and export a ``Flush()`` method which is thread safe.