{"record":{"id":"b47ce590ef0cdd08","repo":"quarkusio/quarkus","slug":"unable-to-pause-scheduler","errorCode":null,"errorMessage":"Unable to pause scheduler","messagePattern":"Unable to pause scheduler","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"extensions/quartz/runtime/src/main/java/io/quarkus/quartz/runtime/QuartzSchedulerImpl.java","lineNumber":356,"sourceCode":"    }\n\n    @Override\n    public String implementation() {\n        return Scheduled.QUARTZ;\n    }\n\n    @Override\n    public void pause() {\n        if (!isStarted()) {\n            throw notStarted();\n        }\n        try {\n            if (scheduler != null) {\n                scheduler.standby();\n                events.fireSchedulerPaused();\n            }\n        } catch (SchedulerException e) {\n            throw new RuntimeException(\"Unable to pause scheduler\", e);\n        }\n    }\n\n    @Override\n    public void pause(String identity) {\n        if (!isStarted()) {\n            throw notStarted();\n        }\n        Objects.requireNonNull(identity, \"Cannot pause - identity is null\");\n        if (identity.isEmpty()) {\n            LOGGER.warn(\"Cannot pause - identity is empty\");\n            return;\n        }\n        try {\n            String parsedIdentity = SchedulerUtils.lookUpPropertyValue(identity);\n            QuartzTrigger trigger = scheduledTasks.get(parsedIdentity);\n            if (trigger != null) {\n                scheduler.pauseJob(new JobKey(parsedIdentity, Scheduler.class.getName()));","sourceCodeStart":338,"sourceCodeEnd":374,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/quartz/runtime/src/main/java/io/quarkus/quartz/runtime/QuartzSchedulerImpl.java#L338-L374","documentation":"Quarkus wraps a Quartz SchedulerException thrown while putting the scheduler into standby mode (pause()) into this RuntimeException. Quartz throws SchedulerException when the underlying scheduler or its persistent JobStore fails to process the standby request. The original Quartz exception is attached as the cause.","triggerScenarios":"Calling Scheduler.pause() (io.quarkus.scheduler.Scheduler) when the Quartz scheduler's JobStore (e.g. JDBC store) is unreachable or misconfigured, so scheduler.standby() fails with SchedulerException.","commonSituations":"Database-backed job store with the DB down or connection pool exhausted; clustered Quartz configuration pointing at an unreachable datasource; corrupted qrtz_ tables; scheduler instance failing to serialize job data.","solutions":["Check the cause (SchedulerException) in the stack trace for the underlying JobStore/DB failure","Verify quartz job-store configuration: quarkus.quartz.store-type and datasource availability","If using the JDBC store, confirm the datasource connects (test with a query) and the Quartz tables exist","Restart the application once the backing store is reachable"],"exampleFix":"// before\nscheduler.pause(); // throws RuntimeException\n// after\ntry {\n    scheduler.pause();\n} catch (RuntimeException e) {\n    LOGGER.errorf(e.getCause(), \"Quartz standby failed; check JobStore/DB connectivity\");\n}","handlingStrategy":"try-catch","validationCode":"if (!scheduler.isStarted()) { throw new IllegalStateException(\"Scheduler not started\"); }","typeGuard":null,"tryCatchPattern":"try {\n    scheduler.pause();\n} catch (RuntimeException e) {\n    LOGGER.errorf(e.getCause(), \"Cannot pause scheduler: %s\", e.getCause().getMessage());\n    // alert / degrade\n}","preventionTips":["Monitor the quartz JobStore datasource health before invoking scheduler control operations","Prefer RAM store (store-type=memory) if you don't need persistence and want fewer failure modes","Wrap scheduler admin operations in retry-with-backoff for transient DB issues"],"tags":["quartz","scheduler","pause","jobstore"],"backgroundTag":"scheduler-standby-failed","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}