Skip to content

[Question] why not worker update task instance status after task completes #5993

@lightning-L

Description

@lightning-L

I know that the current design is:

  • worker will execute the task (TaskExecuteThread.java#run)
  • after task is finished, call back service will send TaskExecuteResponseCommand to master
  • then master will update the cache, and save the task status into db. (TaskResponseService.java#persist)

I wonder why not worker update task instance status after task completes. And I noticed that master is checking task instance table to update the process instance status (MasterExecThread.java#runProcess).
After worker updates the task status, it can still send rpc request to master to update the cache.

And what is the benefit the current design(master update the task instance status)?

Metadata

Metadata

Assignees

No one assigned

    Labels

    StalequestionFurther information is requested

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions