added chunk_store, chunk_directory clients, changed some functions to private