added scheduler and fix error after network connection error