AEM 6.3: workflowSession return all workflows (also those started by others) | Community
Skip to main content
jeroend42683933
November 30, 2017

AEM 6.3: workflowSession return all workflows (also those started by others)

  • November 30, 2017
  • 3 replies
  • 3276 views

I want to show all workflow instances on http://localhost:4502/libs/cq/workflow/admin/console/content/instances.html . At the moment it will only show the instanced linked to the user that I currently logged in.

The datasource file (/libs/cq/workflow/admin/console/components/datasource/workflowinstancedatasource/workflowinstancedatasource.jsp) has the following code:

ResultSet<Workflow> resultSet = workflowSession.getWorkflows(states, offset, limit);

The documentation states the following:

How can I get it to return all the workflows not taking into account the access?

PS: I tried using the following but that also takes in account the access:

workflowSession.getAllWorkflows();

Greetings

Jeroen

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

3 replies

smacdonald2008
November 30, 2017

The information is stated in the docs here:

com.adobe.granite.workflow.WorkflowSession

Workflow[] getAllWorkflows() returns all worflows that the current workflow session has access to. 

YOu cannot get instances for which the wf session cannot access.

joerghoh
Adobe Employee
Adobe Employee
November 30, 2017

IIRC the "standard" workflow session uses an admin session internally.

Jörg

jeroend42683933
December 1, 2017

I now use the service user session but I am still not able to get other users workflow instances, any ideas?

May 8, 2019

Is there any update to jeroend42683933​ question?

getAdministrativeResourceResolver' is deprecated so how would one make this work now. My service user (that I gave all possible permissions) is still not able to retrieve all using the workflowSession.

Thanks,

Nandhini

abdulr83376048
May 15, 2019

Did you try adding your user/group as a Superuser (cq.workflow.superuser) under 'Adobe Granite Workflow Service' config.

Make sure you have 'RMCD' permissions for '/etc/workflow/instances'