refactored dhpc example to use the schedule plugin

minor changes to schedule API