Refactored ServiceMethodHandlerFactory for more flexibility