defining services using different methods