extracted the logic of starting parse in separated file