Removes a workflow from the system

@param workflowId      the id of the workflow to be deleted
@param archiveWorkflow flag to indicate if the workflow should be archived before deletion
14564
public void deleteWorkflow(String workflowId, boolean archiveWorkflow) {
        Preconditions.checkArgument(StringUtils.isNotBlank(workflowId), "Workflow id cannot be blank");

        Object[] params = new Object[]{"archiveWorkflow", archiveWorkflow};
        delete(params, "workflow/{workflowId}/remove", workflowId);
    }
54602
@Override
    public void deleteArchive(ModuleId moduleId) throws IOException {
        Objects.requireNonNull(moduleId, "moduleId");
        cassandra.deleteRow(moduleId.toString());
    }
846184
public void document_id_DELETE(String id) throws IOException {
		String qPath = "/me/document/{id}";
		StringBuilder sb = path(qPath, id);
		exec(qPath, "DELETE", sb.toString(), null);
	}
423978
def delete(cls, uuid):
        """"""
        to_delete = Workflow.query.get(uuid)
        db.session.delete(to_delete)
281535
@Override
	public void removeByOrganizationId(long organizationId) {
		for (CommerceAccountOrganizationRel commerceAccountOrganizationRel : findByOrganizationId(
				organizationId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null)) {
			remove(commerceAccountOrganizationRel);
		}
	}
432910
private void onCleanExit(final String processId) {
    this.onResourceStatus(
        ResourceStatusEventImpl.newBuilder()
            .setIdentifier(processId)
            .setState(State.DONE)
            .setExitCode(0)
            .build()
    );
  }
1207496
@Override
    public void deleteById(ID id) {
        Assert.notNull(id, "id to be deleted should not be null");

        operation.deleteById(information.getCollectionName(), id, null);
    }
186679
public void project_serviceName_volume_snapshot_snapshotId_DELETE(String serviceName, String snapshotId) throws IOException {
		String qPath = "/cloud/project/{serviceName}/volume/snapshot/{snapshotId}";
		StringBuilder sb = path(qPath, serviceName, snapshotId);
		exec(qPath, "DELETE", sb.toString(), null);
	}
16502
@Service
    public void terminateWorkflow(String workflowId, String reason) {
        workflowExecutor.terminateWorkflow(workflowId, reason);
    }
417323
public void unregisterWorkManager(WorkManager wm)
   {
      if (wm != null)
      {
         if (wm.getName() == null || wm.getName().trim().equals(""))
            throw new IllegalArgumentException("The name of WorkManager is invalid: " + wm);

         if (trace)
            log.tracef("Unregistering WorkManager: %s", wm);

         if (workmanagers.keySet().contains(wm.getName()))
         {
            workmanagers.remove(wm.getName());

            // Clear any events
            if (wm instanceof DistributedWorkManager)
            {
               WorkManagerEventQueue wmeq = WorkManagerEventQueue.getInstance();
               List<WorkManagerEvent> events = wmeq.getEvents(wm.getName());
               events.clear();
            }
         }
      }
   }
1003837
func (s *SignalWorkflowExecutionInput) SetWorkflowId(v string) *SignalWorkflowExecutionInput {
	s.WorkflowId = &v
	return s
}
737214
public function onAfterDelete()
    {
        parent::onAfterDelete();
        $wfActionInstances = WorkflowActionInstance::get()
            /** @skipUpgrade */
            ->leftJoin('WorkflowInstance', '"WorkflowInstance"."ID" = "WorkflowActionInstance"."WorkflowID"')
            ->where(sprintf('"BaseActionID" = %d AND ("WorkflowStatus" IN (\'Active\',\'Paused\'))', $this->ID));
        foreach ($wfActionInstances as $wfActionInstance) {
            $wfInstances = WorkflowInstance::get()->filter('CurrentActionID', $wfActionInstance->ID);
            foreach ($wfInstances as $wfInstance) {
                $wfInstance->Groups()->removeAll();
                $wfInstance->Users()->removeAll();
                $wfInstance->delete();
            }
            $wfActionInstance->delete();
        }
        // Delete outbound transitions
        $transitions = WorkflowTransition::get()->filter('ActionID', $this->ID);
        foreach ($transitions as $transition) {
            $transition->Groups()->removeAll();
            $transition->Users()->removeAll();
            $transition->delete();
        }
    }
1004
public void deleteFlowConfigWithStateStore(FlowId flowId)
      throws RemoteInvocationException {
    LOG.debug("deleteFlowConfig and state store with groupName " + flowId.getFlowGroup() + " flowName " +
        flowId.getFlowName());

    DeleteRequest<FlowConfig> deleteRequest = _flowconfigsV2RequestBuilders.delete()
        .id(new ComplexResourceKey<>(flowId, new FlowStatusId())).setHeader(DELETE_STATE_STORE_KEY, Boolean.TRUE.toString()).build();
    ResponseFuture<EmptyRecord> response = _restClient.get().sendRequest(deleteRequest);

    response.getResponse();
  }
872045
public void deleteById(String id) {
    if (idToVersion.containsKey(id)) {
      String version = idToVersion.remove(id);
      expirationVersion.remove(version);
      versionToItem.remove(version);
      if (collectionCachePath != null
          && !collectionCachePath.resolve(version).toFile().delete()) {
        log.debug("couldn't delete " + version);
      }
    }
  }
199073
public void removeWorkflow(String id) {
        final Workflow<?> wf = workflowMap.remove(id);
        if (wf != null) {
            WorkflowAccessor.setProcessingState(wf, ProcessingState.FINISHED);
            ticketPoolManager.release(wf);
            statisticsCollector.submit(getEngineId() + "." + wf.getClass().getSimpleName() + ".ExecutionTime", 1, System.currentTimeMillis() - wf.getCreationTS().getTime(), TimeUnit.MILLISECONDS);
        }
    }
831676
def delete_archive_dir(self):
        
        logger.debug("Deleting: " + self.archive_dir)
        shutil.rmtree(self.archive_dir, True)
542839
public void deleteFlowConfig(FlowId flowId)
      throws RemoteInvocationException {
    LOG.debug("deleteFlowConfig with groupName {}, flowName {}", flowId.getFlowGroup(), flowId.getFlowName());

    DeleteRequest<FlowConfig> deleteRequest = _flowconfigsV2RequestBuilders.delete()
        .id(new ComplexResourceKey<>(flowId, new FlowStatusId())).build();
    ResponseFuture<EmptyRecord> response = _restClient.get().sendRequest(deleteRequest);

    response.getResponse();
  }