Automationprompt onlyIntermediate

Scheduled Job Stabilizer

Monitors and stabilizes scheduled jobs by automatically detecting failures, analyzing causes, and applying corrective measures. The agent iterates through job status checks and stabilization actions until the job achieves five consecutive successful runs or reaches the maximum iteration limit.

← all loops
AutomationScheduled JobsStabilizationSelf-PacingError Handling

Goal

Stabilize scheduled jobs

How to Run

Initiate the Scheduled Job Stabilizer loop to automatically detect and resolve issues with scheduled jobs. The agent will monitor job execution, apply fixes, and verify stability over up to 10 iterations until the exit condition is met.

  1. 01

    Initialize Loop

    Start the loop by providing the kickoff prompt to the agent environment.

  2. 02

    Check Job Status

    Execute the 'job status check' command to retrieve the latest run results and health metrics.

  3. 03

    Analyze Results

    Review the output for errors, failures, or instability indicators. Determine if corrective actions are needed.

  4. 04

    Apply Stabilization

    If issues are detected, apply targeted fixes (e.g., configuration changes, resource adjustments) to improve job reliability.

  5. 05

    Evaluate Exit Condition

    Check if the last five runs were successful. If yes, exit the loop. If not, and iterations remain, repeat the process.

Workflow Steps

  1. 01

    Act

    Identify and apply corrective actions to address job failures or instability based on previous check results.

  2. 02

    Run Check Command

    Execute the 'job status check' to retrieve current job execution status and history.

  3. 03

    Inspect Result

    Analyze the output for success patterns, errors, or trends that indicate job stability.

  4. 04

    Evaluate Exit Condition

    Determine if the last five runs of the job have succeeded. Exit if condition met; otherwise, proceed or stop based on iteration count.

Kickoff Prompt

Start the "Scheduled Job Stabilizer" loop.

Goal: Stabilize scheduled jobs
Max iterations: 10
Between iterations run: job status check
Exit when: Last 5 runs succeed


Stabilize the scheduled job by continuously checking its execution status and applying fixes until the last 5 runs succeed or 10 iterations are reached. Begin by running the job status check and analyzing the results.

Self-pace this loop. After each iteration, run `job status check` and evaluate the output, and only continue if the exit condition is not met (Last 5 runs succeed). Stop when the exit condition passes or 10 iterations are reached. Give a short status update each pass.

Guardrails

hardcoded
  • ·Do not modify the 'job status check' command or its expected output format.
  • ·Ensure the exit condition (last 5 runs succeed) is strictly evaluated after each iteration.
  • ·Limit the total number of iterations to 10 to prevent infinite loops.
  • ·Preserve the original job configuration if stabilization fails to resolve the issue.
  • ·Verify job exists and is accessible before initiating stabilization actions.

Flow Diagram

rendering…

Related loops — Automation