refactoring the document store to take an IKVStore object, removing old interface and the in-memory implementation