kill a AEM workflow using /var path | Community
Skip to main content
Adobe Champion
May 5, 2023
Solved

kill a AEM workflow using /var path

  • May 5, 2023
  • 3 replies
  • 1739 views

There is a need to kill a workflow.

There are 1000's of dam update workflow in the instances tab and hence cannot locate this custom workflow from workflow instance tab and terminate it.

I ran a query as below to locate the workflow /var path. This is actually in production , we need to do this.

 

path=/var/workflow/instances
type=cq:Workflow
1_property=status
1_property.value=RUNNING
2_property=modelId
2_property.value=/var/workflow/models/dam/test-staging-assets
p.limit=-1

 

So, can someone help me how I can terminate this workflow using this /var path?

I tried using the workflow remover from ACS commons, but it is not working and still I can see this workflow is active.

Do we have any JMX console, where it is possible to give the /var path t terminate a workflow?

 

@arunpatidar 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by MayurSatav

Yes, it is possible to terminate a workflow using JMX console. Follow the steps below:

  1. Open the JMX console by navigating to http://localhost:4502/system/console/jmx
  2. In the MBean search box, type "WorkflowService" and hit enter. This will display the WorkflowService MBean.
  3. Expand the WorkflowService MBean and navigate to the Operations tab.
  4. Locate the terminateWorkflowInstance operation and click on it.
  5. In the terminateWorkflowInstance operation parameters, enter the path of the workflow instance you want to terminate in the workflowInstancePath parameter. This path should start with /var/workflow/instances.
  6. Click on the Invoke button to terminate the workflow instance.

3 replies

MayurSatav
Community Advisor and Adobe Champion
MayurSatavCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
May 5, 2023

Yes, it is possible to terminate a workflow using JMX console. Follow the steps below:

  1. Open the JMX console by navigating to http://localhost:4502/system/console/jmx
  2. In the MBean search box, type "WorkflowService" and hit enter. This will display the WorkflowService MBean.
  3. Expand the WorkflowService MBean and navigate to the Operations tab.
  4. Locate the terminateWorkflowInstance operation and click on it.
  5. In the terminateWorkflowInstance operation parameters, enter the path of the workflow instance you want to terminate in the workflowInstancePath parameter. This path should start with /var/workflow/instances.
  6. Click on the Invoke button to terminate the workflow instance.
P_V_NairAdobe ChampionAuthor
Adobe Champion
May 5, 2023

@mayursatav  Can you please drop in a screenshot as well? I am unable to locate Mbean Searchbox

MayurSatav
Community Advisor and Adobe Champion
Community Advisor and Adobe Champion
May 5, 2023

1. you can use command + F (CTRL + F in windows) to search workflow.

 

2. Click on the workflow and search for the path and use invoke

above screenshots are just for reference.

P_V_NairAdobe ChampionAuthor
Adobe Champion
May 5, 2023

@mayursatav  Unfortunately I am not seeing purge workflows under Operations