Content Services (ECM)
Process Services (BPM)
Application Development Framework
Digital Business Platform
Announcements & Opportunities
Alfresco Ambassador Program
Alfresco Process Services & Activiti (BPM)
to create and rate content, and to follow, bookmark, and share content with other members. Not a member?
runtimeService in groovy ScriptTask
Question asked by
on Jun 27, 2012
on Jun 27, 2012 by frederikheremans1
Show 0 Likes
Is it possible to access the runtimeService from within a groovy scriptask?
No one else has this question
Mark as assumed answered
This content has been marked as final.
Show 1 comment
(Required, will not be published)
Jun 27, 2012 7:40 AM
The activiti services aren't exposed in any delegate's (serviceTask, script task, …). Since delegates are executed WITHIN the activiti-context, there is a transaction running. So if you want to use the runtimeService from within a process, you should take into account that the state of the current process isn't reflected the way is is currently, but rather the way it was before the process was flowing (transaction not committed).
So in general, it's not advised to use the services at that point for current process-related things, unless you're know what you're doing. In this case, you should create your own mechanism to expose the services in your groovy-task. This can be done by registering the services as "bean" in the activiti beans configuration.
, org.activiti.engine.impl.scripting.BeansResolverFactory and org.activiti.engine.impl.scripting.ScriptBindings
Show 0 Likes
Retrieving data ...
mail task config(activiti rest)
How can i return a value from AJAX in Alfresco
Sample process in eclipse activiti
actionExecuter mandatory parameter with custom ftl