I've setup my AdoJobStore on the server and all my jobs are running perfectly. Now I am writing a remote client to manage all my jobs.
Scheduling new jobs is straightforward enough, but I can't seem to retrieve a list of existing jobs in version 2.0. All the resources I found did something like the following.
var groups = sched.JobGroupNames;
for (int i = 0; i < groups.Length; i++)
{
string[] names = sched.GetJobNames(groups[i]);
for (int j = 0; j < names.Length; j++)
{
var currentJob = sched.GetJobDetail(names[j], groups[i]);
}
}
The problem I'm facing is that GetJobNames has been removed, and looking at the source code, has been moved to the base class JobStoreSupport, which JobStoreCMS inherits from. The method has however been marked as protected, so it is inaccessible from the outside.
How would one go about retrieving a job list in 2.0?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…