refactor data path