8000 Job Completion Notification · Issue #205 · ajvb/kala · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Job Completion Notification #205
Closed
@tooolbox

Description

@tooolbox

Right now many unit tests are racy because the jobs involve shelling out to run date or a similar command, and there is no way for the scheduler of a job to know when that job has actually completed, so we rely on time.Sleep() and similar mechanisms.

This tends to create a problem for small time.Sleep() values or when running tests with -count # for testing durability.

A likely solution would be to add something like context.Done() to job.Job wherein the caller gets a channel which can be read from to block execution until the job completes.

Note: the behavior is not racey, but the tests are in some cases.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0