add priority based scheduling