Skip to content

Add signal handler for unclean shutdown #1

@jpmckinney

Description

@jpmckinney

Like in Scrapy https://github.com/scrapy/scrapy/blob/c316ca45a5b1b19622c96049c9378d8c45adba60/scrapy/crawler.py#L255

We'd need to set up a communication method between the threads and the main thread. You can't just call sys.exit() from the main thread, since Python handles this by calling wait_for_thread_shutdown().

For now, consumer callbacks should be designed to do a modest amount of work per message.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions