Refactor taskAction resource to take in a Task definition uuid in add…#431
Refactor taskAction resource to take in a Task definition uuid in add…#431gitcliff wants to merge 1 commit intoopenmrs:masterfrom
Conversation
|
@ibacher kindly requesting for your review on this pr |
| case SCHEDULETASK: | ||
| scheduleTasks(taskDefinitions); | ||
| break; | ||
| case RESCHEDULETASK: | ||
| reScheduleTasks(taskDefinitions); | ||
| break; | ||
| case DELETE: | ||
| deleteTasks(taskDefinitions); | ||
| break; | ||
| case SHUTDOWNTASK: | ||
| shutDownTasks(taskDefinitions); | ||
| break; | ||
| case RESCHEDULEALLTASKS: | ||
| reScheduleAllTasks(); | ||
| break; | ||
| case RUNTASK: | ||
| runTasks(taskDefinitions); | ||
| break; |
There was a problem hiding this comment.
These case statements should be indented one more level.
There was a problem hiding this comment.
yes sure,going to add it
| public TaskDefinition getByUniqueId(String uniqueId) { | ||
| TaskDefinition taskDefinition = taskServiceWrapper.getTaskByName(uniqueId); | ||
| if (taskDefinition == null) { | ||
| taskDefinition = taskServiceWrapper.getTaskByUuid(uniqueId); |
There was a problem hiding this comment.
I can see why we want to add the functionality to get a task by UUID, but do we also want to remove the functionality to get the task by ID?
There was a problem hiding this comment.
@ibacher yes i think its ideal to get a task by its UUID and leave the task by ID for internal database identification and operations
|
@ibacher thanks, sure i was going to add the tests . |
link:https://issues.openmrs.org/browse/RESTWS-764