AnsweredAssumed Answered

Invocation of method componentEvent in org.activiti.explorer.ui.task.TaskDetailPanel$4 fail

Question asked by nhhao1996 on Feb 21, 2019
Latest reply on Feb 26, 2019 by nhhao1996

Hi everyone!

I just made a simple process: start -> service task -> end

I create a Java class to implement into service task to save diagram before process end. Here is my code:


public class CaptureProcess implements JavaDelegate{

   public void execute(DelegateExecution delegateExecution) throws Exception {

      ProcessEngine processEngine = ProcessEngines.getDefaultProcessEngine();

      RepositoryService repositoryService = processEngine.getRepositoryService();

      ProcessDefinition processDefinition = repositoryService.createProcessDefinitionQuery()

      String diagramResourceName = processDefinition.getDiagramResourceName();

      InputStream imageStream = repositoryService.getResourceAsStream(
      processDefinition.getDeploymentId(), diagramResourceName);

      FileOutputStream outstream = new FileOutputStream(new File("download-image.png"));

      IOUtils.copy(imageStream, outstream);

I copied jar file when create deployment artifact to my activiti-explorer path, but when I deploy bar file and run, it's appear warning: Invocation of method componentEvent in org.activiti.explorer.ui.task.TaskDetailPanel$4 fail.


Can you tell my what's wrong with my code?