Skip to content

Scheduler can't restart until long-running local executor(s) finish #1389

@xiaoliangsc

Description

@xiaoliangsc

Dear Airflow Maintainers,

Before I tell you about my issue, let me describe my environment:

Environment

  • Version of Airflow (e.g. a release version, running your own fork, running off master -- provide a git log snippet): 1.7.0
  • Airflow components and configuration, if applicable (e.g. "Running a Scheduler with CeleryExecutor")
    LocalExecutor, set parallelism = 128
  • Example code to reproduce the bug (as a code snippet in markdown)
  • Screen shots of your DAG's graph and tree views:
  • Stack trace if applicable:
  • Operating System: (Windows Version or $): Linux blizzard-flowrida 3.16.0-4-amd64 Improving the search functionality in the graph view #1 SMP Debian 3.16.7-ckt20-1+deb8u3 (2016-01-17) x86_64 GNU/Linux
  • Python Version: $ python --version: 2.7.9

Now that you know a little about me, let me tell you about the issue I am having:

Description of Issue

  • What did you expect to happen?

When scheduler runs out of num_runs (we set to 200), it should force local executor's running task to stop. (e.g sends a kill signal).

  • What happened instead?

The current implementation waits until each executor drains its queue. However, if we have long-running tasks, e.g sensor_task to detect a file exists, scheduler would simply wait there, doing nothing.

I'm not listing any code here because I feel it's pretty clear what the issue is, can you please help look into it or suggest a workaround? Thanks a lot!

Metadata

Metadata

Assignees

No one assigned

    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