Moved local_session to separate file
Refactored cache support

Added support for append/offset writes to cache
Fixed several synchronisation issues between cache and backend
Added metadata support to cache