changing scheduler to be a implicity parameter