added job scheduling
fixed job related bugs