Refactor address service for choose different threads