Skip to content

Final Job Statuses are not enough for the Plugin pipeline #1707

@mlodic

Description

@mlodic

Originally, Connectors and Visualizers did not exist. Now, we have different plugins and we'll add more in the future.

The original list of available statuses for a Job is not enough to represent the required statuses of the job. Right now there is a final status once the analyzers have finished to be executed. In this way, we lose the information regarding the fact that the connectors and the visualizers (or any other future plugin) have finished, independently from their order.

Actual order is:
analyzers -> connectors -> visualizers

Actual list:

class Status(models.TextChoices):
    PENDING = "pending", "pending"
    RUNNING = "running", "running"
    REPORTED_WITHOUT_FAILS = "reported_without_fails", "reported_without_fails"
    REPORTED_WITH_FAILS = "reported_with_fails", "reported_with_fails"
    KILLED = "killed", "killed"
    FAILED = "failed", "failed"

    @classmethod
    def final_statuses(cls) -> typing.List["Status"]:
        return [
            cls.REPORTED_WITHOUT_FAILS,
            cls.REPORTED_WITH_FAILS,
            cls.KILLED,
            cls.FAILED,
        ]

An important thing to keep in mind is that it would be cool to maintain retrocompatibility with old clients to avoid to break them with this change.

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