class LongRunningProcessStopTask extends LongRunningProcessTask<List<LongRunningProcessStatus>> {

    @Override public List<LongRunningProcessStatus> call() {
        ArrayList<LongRunningProcessStatus> res = new ArrayList<>();

        for (UUID prodId : procIds)
            res.add(stopProcess(prodId));

        // All-or-nothing strategy. Processes will be removed only if all processes can be removed.
        if (clear)
            removeProcessesFromMetadataStorage();

        return res;
    }

    public  LongRunningProcessStopTask(List<UUID> procIds, boolean clear);

}