java.lang.IllegalStateException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Quartz not scaling well
    via by Unknown author,
  • If a trigger is selected as it is being deleted, a _JobPersistenceException_ may be thrown if the following sequence occurs: # (Thread 1) In _StdJDBCDelegate.selectTrigger()_, the trigger is selected, most of the details are retrieved, # (Thread 2) The trigger is deleted, # (Thread 1) In _SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties()_ the trigger is missing, so an _IllegalStateException_ is thrown. This is somewhat common in our application as one of the first actions when a job starts is to update the user with the next time the job will run, requiring an inspection of all the job's triggers. If the trigger done not repeat, it will be deleted after it fires. {noformat:title=Stack Trace} org.quartz.JobPersistenceException: Couldn't obtain triggers for job: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getNextScheduledStartTime(QuartzSchedulerWrapper.java:331) ~[scheduler-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerManager.getNextScheduledStartTime(QuartzSchedulerManager.java:206) ~[scheduler-4.0-SNAPSHOT.jar:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_21] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[na:1.7.0_21] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.7.0_21] at java.lang.reflect.Method.invoke(Method.java:601) ~[na:1.7.0_21] at com.google.inject.internal.DelegatingInvocationHandler.invoke(DelegatingInvocationHandler.java:37) ~[guice-3.0.jar:na] at com.sun.proxy.$Proxy128.getNextScheduledStartTime(Unknown Source) ~[na:na] at com.ze.datamanager.execution.manager.ExecutionManager.prePopulateNextScheduledExecution(ExecutionManager.java:403) ~[execution-manager-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.execution.manager.ExecutionManager.executionStarted(ExecutionManager.java:233) ~[execution-manager-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.process.ProcessJob.createAndExecute(ProcessJob.java:257) ~[quartz-process-job-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.process.ProcessJob.execute(ProcessJob.java:238) ~[quartz-process-job-4.0-SNAPSHOT.jar:na] at org.quartz.core.JobRunShell.run(JobRunShell.java:213) ~[quartz-2.1.7.jar:na] at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557) [quartz-2.1.7.jar:na] Caused by: org.quartz.JobPersistenceException: Couldn't obtain triggers for job: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2135) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport$28.execute(JobStoreSupport.java:2121) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3798) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreTX.executeInLock(JobStoreTX.java:93) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeWithoutLock(JobStoreSupport.java:3703) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2118) ~[quartz-2.1.7.jar:na] at org.quartz.core.QuartzScheduler.getTriggersOfJob(QuartzScheduler.java:1423) ~[quartz-2.1.7.jar:na] at org.quartz.impl.StdScheduler.getTriggersOfJob(StdScheduler.java:452) ~[quartz-2.1.7.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getTriggers(QuartzSchedulerWrapper.java:310) ~[scheduler-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getNextScheduledStartTime(QuartzSchedulerWrapper.java:322) ~[scheduler-4.0-SNAPSHOT.jar:na] ... 13 common frames omitted Caused by: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties(SimpleTriggerPersistenceDelegate.java:95) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTrigger(StdJDBCDelegate.java:1801) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTriggersForJob(StdJDBCDelegate.java:1688) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2132) ~[quartz-2.1.7.jar:na] ... 22 common frames omitted {noformat}
    via by Wesley Hartford,
  • org.quartz.JobPersistenceException: Couldn't acquire next trigger: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: org.quartz.JobPersistenceException: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?]] at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2848) at org.quartz.impl.jdbcjobstore.JobStoreSupport$40.execute(JobStoreSupport.java:2759) at org.quartz.impl.jdbcjobstore.JobStoreSupport$40.execute(JobStoreSupport.java:2757) at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3787) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTriggers(JobStoreSupport.java:2756) at org.quartz.core.QuartzSchedulerThread.run(QuartzSchedulerThread.java:272) Caused by: org.quartz.JobPersistenceException: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?] at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1533) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2808) ... 5 more Caused by: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties(SimpleTriggerPersistenceDelegate.java:95) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTrigger(StdJDBCDelegate.java:1819) at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1531) ... 6 more
    via by seetha Lakshmi,
  • org.quartz.JobPersistenceException: Couldn't acquire next trigger: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: org.quartz.JobPersistenceException: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?]] at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2848) at org.quartz.impl.jdbcjobstore.JobStoreSupport$40.execute(JobStoreSupport.java:2759) at org.quartz.impl.jdbcjobstore.JobStoreSupport$40.execute(JobStoreSupport.java:2757) at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3787) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTriggers(JobStoreSupport.java:2756) at org.quartz.core.QuartzSchedulerThread.run(QuartzSchedulerThread.java:272) Caused by: org.quartz.JobPersistenceException: Couldn't retrieve trigger: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?] at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1533) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2808) ... 5 more Caused by: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'MandateManagement.3092665_TRIGGERCREATION_18.02.2015 08:40:14' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'quartzSchedulerJobFactory' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties(SimpleTriggerPersistenceDelegate.java:95) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTrigger(StdJDBCDelegate.java:1819) at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1531) ... 6 more
    via by seetha Lakshmi,
  • If a trigger is selected as it is being deleted, a _JobPersistenceException_ may be thrown if the following sequence occurs: # (Thread 1) In _StdJDBCDelegate.selectTrigger()_, the trigger is selected, most of the details are retrieved, # (Thread 2) The trigger is deleted, # (Thread 1) In _SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties()_ the trigger is missing, so an _IllegalStateException_ is thrown. This is somewhat common in our application as one of the first actions when a job starts is to update the user with the next time the job will run, requiring an inspection of all the job's triggers. If the trigger done not repeat, it will be deleted after it fires. {noformat:title=Stack Trace} org.quartz.JobPersistenceException: Couldn't obtain triggers for job: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? [See nested exception: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getNextScheduledStartTime(QuartzSchedulerWrapper.java:331) ~[scheduler-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerManager.getNextScheduledStartTime(QuartzSchedulerManager.java:206) ~[scheduler-4.0-SNAPSHOT.jar:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_21] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[na:1.7.0_21] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.7.0_21] at java.lang.reflect.Method.invoke(Method.java:601) ~[na:1.7.0_21] at com.google.inject.internal.DelegatingInvocationHandler.invoke(DelegatingInvocationHandler.java:37) ~[guice-3.0.jar:na] at com.sun.proxy.$Proxy128.getNextScheduledStartTime(Unknown Source) ~[na:na] at com.ze.datamanager.execution.manager.ExecutionManager.prePopulateNextScheduledExecution(ExecutionManager.java:403) ~[execution-manager-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.execution.manager.ExecutionManager.executionStarted(ExecutionManager.java:233) ~[execution-manager-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.process.ProcessJob.createAndExecute(ProcessJob.java:257) ~[quartz-process-job-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.process.ProcessJob.execute(ProcessJob.java:238) ~[quartz-process-job-4.0-SNAPSHOT.jar:na] at org.quartz.core.JobRunShell.run(JobRunShell.java:213) ~[quartz-2.1.7.jar:na] at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557) [quartz-2.1.7.jar:na] Caused by: org.quartz.JobPersistenceException: Couldn't obtain triggers for job: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2135) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport$28.execute(JobStoreSupport.java:2121) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3798) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreTX.executeInLock(JobStoreTX.java:93) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeWithoutLock(JobStoreSupport.java:3703) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2118) ~[quartz-2.1.7.jar:na] at org.quartz.core.QuartzScheduler.getTriggersOfJob(QuartzScheduler.java:1423) ~[quartz-2.1.7.jar:na] at org.quartz.impl.StdScheduler.getTriggersOfJob(StdScheduler.java:452) ~[quartz-2.1.7.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getTriggers(QuartzSchedulerWrapper.java:310) ~[scheduler-4.0-SNAPSHOT.jar:na] at com.ze.datamanager.scheduler.QuartzSchedulerWrapper.getNextScheduledStartTime(QuartzSchedulerWrapper.java:322) ~[scheduler-4.0-SNAPSHOT.jar:na] ... 13 common frames omitted Caused by: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.6da64b5bd2ee-f6e66122-1a99-4d83-bd60-0281c257e631' and statement: SELECT * FROM ZE_DM.QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'action-execution-group-run-now' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties(SimpleTriggerPersistenceDelegate.java:95) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTrigger(StdJDBCDelegate.java:1801) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTriggersForJob(StdJDBCDelegate.java:1688) ~[quartz-2.1.7.jar:na] at org.quartz.impl.jdbcjobstore.JobStoreSupport.getTriggersForJob(JobStoreSupport.java:2132) ~[quartz-2.1.7.jar:na] ... 22 common frames omitted {noformat}
    via by Wesley Hartford,
  • Quartz not scaling well
    via by pitdingo,
    • java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.kissaTrigger' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'org.springframework.scheduling.quartz.SchedulerFactoryBean#0' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ?] at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1533) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2808) Caused by: java.lang.IllegalStateException: No record found for selection of Trigger with key: 'DEFAULT.kissaTrigger' and statement: SELECT * FROM QRTZ_SIMPLE_TRIGGERS WHERE SCHED_NAME = 'org.springframework.scheduling.quartz.SchedulerFactoryBean#0' AND TRIGGER_NAME = ? AND TRIGGER_GROUP = ? at org.quartz.impl.jdbcjobstore.SimpleTriggerPersistenceDelegate.loadExtendedTriggerProperties(SimpleTriggerPersistenceDelegate.java:95) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTrigger(StdJDBCDelegate.java:1819) at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1531) ... 2 more
    No Bugmate found.