Pulse
GithubCloud(Pulsecron)
  • What is Pulse?
  • Why Pulse?
  • Quick Start
  • DOCS
    • Setup & Config
      • Connection
      • Config
        • Name
        • ProcessEvery
        • DefaultConcurrency
        • MaxConcurrency
        • LockLimit
        • DefaultLockLimit
        • DefaultLockLifetime
        • Sort
        • ResumeOnRestart
    • Defining Job Processors
    • Managing Job Processor
      • Start
      • Stop
    • Creating Jobs
      • Every
      • Schedule
      • Now
      • Create
    • Managing Jobs
      • Jobs
      • Cancel
      • Disable
      • Enable
      • Purge
      • isRunning
      • isExpired
      • Manually working
        • Save
        • Unique
        • RepeatEvery
        • RepeatAt
        • Schedule
        • Remove
        • Priority
        • Touch
        • SetShouldSaveResult
        • Fail
        • Run
        • Disable
        • Enable
Powered by GitBook
On this page
  • job.disable()
  • Example Usage
  • Parameters
  • Returns

Was this helpful?

Edit on GitHub
  1. DOCS
  2. Managing Jobs
  3. Manually working

Disable

PreviousRunNextEnable

Last updated 1 year ago

Was this helpful?

job.disable()

The disable method sets a job's status to disabled, preventing it from being run by the job processing system. This is useful for temporarily halting a job's execution without permanently removing it from the job queue.

This does NOT save the job in the database. you must explicitly declare if you want to save it

Example Usage

const job = pulse.create('test', {});
job.disable();
job.save(); // If you want to save it

Parameters

Returns

  • Job: Returns the job instance, allowing for method chaining. This facilitates further modifications to the job or chaining additional method calls.

save()