Skip to content

Add pause_processing Management Command #1588

@avrohomgottlieb

Description

@avrohomgottlieb

Context

In Issue #1563, requirements were gathered on how to gracefully terminate and recreate jobs upon redeploy.

The conclusion was to:

  • Query for all processing jobs
  • Terminate those jobs
  • Clone those jobs and save their state as JobStates.PENDING

This will ultimately allow for those jobs to be re-submitted by the submit_processing command, which runs every 30 minutes as a cron job.

Problem or idea

A management command should be written, called pause_processing, which implements this command.

A further issue will address how this command is integrated into the deploy sequence.

Solution or next step

  • Add management command pause_processing which calls Job::terminate_processing and then Job::create_retry_jobs on the returned terminated jobs
  • Add tests

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions