Clear cache on any repository update

Clear simple cache when CRUD operations on a repo happen or when the metadata is updated. Also clear cache when clients send new data.