code: 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);
          }
      }
docs: For internal use only!!
  
  @param id
  workflow instance id