Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to get Listing of Jobs in the Quartz Scheduler

I am trying to fetch all jobs registered with the Quartz scheduler for a particular group. here is my piece of code

CustomSchdularFactory.getSchedulerInstance().getJobKeys(groupEquals(group));

here group is a String variable holding the name of group whose associated jobs i want to fetch. while using the above code i am getting following error

The method getJobKeys(GroupMatcher<JobKey>) in the type Scheduler is not applicable for the arguments (GroupMatcher<Key<Key<T>>>)

i am not sure why this error is occurring as i took the reference from Quartz official documents

ListJobs

like image 737
Umesh Awasthi Avatar asked Feb 20 '23 01:02

Umesh Awasthi


1 Answers

Use jobGroupEquals instead of groupEquals

CustomSchdularFactory.getSchedulerInstance().getJobKeys(jobGroupEquals(group));

and it will work for you.

like image 94
JEE consult Avatar answered Mar 03 '23 11:03

JEE consult