cancel
Showing results for 
Search instead for 
Did you mean: 

Need info on Deleting Task

sai576
Champ on-the-rise
Champ on-the-rise
Hi,

      I am using activiti-5.13,Now my question is i am trying to delete the task using rest uri (DELETE) runtime/tasks/{taskId}, the task is not deleted it shows the response as

{
    "errorMessage": "Cannot delete a task that is part of a process-instance.",
    "statusCode": 403
}

I am trying this one in different workflows,i am not understand this one  can u explain in which situation we can use this uri, because generally if u take any task it is definitely with in the part of a process-instance,Please any one could explain this clearly.

Thanks & Regards
Sai Kumar R

3 REPLIES 3

trademak
Star Contributor
Star Contributor
Hi,

What's the reason for you to delete a task that's running as part of a process instance?
A task should be completed and a process instance can be deleted.
The DELETE task call can be used for standalone tasks (tasks that don't run as part of process instance).

Best regards,

sai576
Champ on-the-rise
Champ on-the-rise
The DELETE task call can be used for standalone tasks (tasks that don't run as part of process instance).

Can u Please elaborate above one.Generally task is part of process instance only right.

Thanks & Regards
Sai Kumar R

jbarrez
Star Contributor
Star Contributor
Tasks in a process instance cannot be deleted. They can be completed, or delegated. But not deleted, cause what would need to happen then in the process instance?