Inconsistency between the Java and REST APIs

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2014 10:38 AM
Hi,
I have just noticed an inconsistency between the Java and REST APIs that has become apparent with a change introduced in Activiti 5.16.1 (https://github.com/Activiti/Activiti/commit/61182262f1af35f71dcd6c926647d36602a4e117).
The Java API call to delete a process instance is:
The REST call to delete a process instance is:
The linked commit above adds "ACTIVITI_DELETED" as a default placeholder for the delete reason if it is empty. The issue is that when a process is deleted via REST, there is no argument available for a reason and thus it is always empty (hence it always defaults to the placeholder). This has become apparent as the "ACTIVITI_DELETED" placeholder String has made it up to our UI layer after an Activiti update.
Would it make sense to add a deleteReason argument to the REST call or does this have to be handled by a (hacky) String comparison against the placeholder?
Thanks,
Misha
I have just noticed an inconsistency between the Java and REST APIs that has become apparent with a change introduced in Activiti 5.16.1 (https://github.com/Activiti/Activiti/commit/61182262f1af35f71dcd6c926647d36602a4e117).
The Java API call to delete a process instance is:
public void deleteProcessInstance(String processInstanceId, String deleteReason)
The REST call to delete a process instance is:
DELETE runtime/process-instances/{processInstanceId}
The linked commit above adds "ACTIVITI_DELETED" as a default placeholder for the delete reason if it is empty. The issue is that when a process is deleted via REST, there is no argument available for a reason and thus it is always empty (hence it always defaults to the placeholder). This has become apparent as the "ACTIVITI_DELETED" placeholder String has made it up to our UI layer after an Activiti update.
Would it make sense to add a deleteReason argument to the REST call or does this have to be handled by a (hacky) String comparison against the placeholder?
Thanks,
Misha
Labels:
- Labels:
-
Archive
2 REPLIES 2

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2014 05:07 AM
Hi Misha,
Yes that makes a lot of sense. Could you create a JIRA issue for this?
Thanks,
Yes that makes a lot of sense. Could you create a JIRA issue for this?
Thanks,

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2014 05:13 AM
