Further refactoring of data service