adding base scheduler code