package core type Scheduler interface { // Submit job for execution with this scheduler. Only returns // an error when enqueuing failed. On success, returns a unique // id for use with other methods of this scheduler. Submit(job Collecter) (JobId, error) // Return a JobInfo for the job with given id. Info(id JobId) (JobInfo, error) // Wait for completion of job with given id. Returns an error // if the id is unknown. WaitFor(id JobId) error }