cancel
Showing results for 
Search instead for 
Did you mean: 

Help with implementing an advanced workflow.----SOLVED

mwarme
Champ in-the-making
Champ in-the-making
I am attempting to implement an advanced workflow in alfresco explorer.  JBPM has been enabled in the global properties.  I have the following files:

contractor_processdefinition.xml
contractor_taskModel.xml
contractor-workflow-messages.properties
web-client-config-custom.xml
workflow-context.xml

From all of the tutorials I've seen, it appears they all need to be saved under /tomcat/shared/classes/alfresco/extension.  When I attempt to start alfresco with all of the files as-is and go to the login page, I get a 404 error–very helpful.  What is confusing to me is that when I do NOT include the workflow-context.xml file, Alfresco starts and spits out a fairly lengthy bunch of errors instead of a login page–but it does start.

I need to determine what mistake I have made with these files, as I'm positive it is syntax-related.  However, the information on what a workflow needs is not really documented at all–there's tons of "cookbooks" with no hard explanation of what is actually required for each input file, just what files must exist and "oh, here's a working (not actually working) example you can copy/paste".

Thus far my experience with attempting to use alfresco has been nothing but negative.  The website here won't even allow me to append additional text files to a post beyond the second, and even prevents me from removing them from the attachments list. 

As I believe I've isolated the problem down to workflow-context.xml, I'll append that file.
8 REPLIES 8

afaust
Legendary Innovator
Legendary Innovator
Hello,

have you had a look at <a href="http://jmuras.com/blog/2012/creation-of-workflow-in-alfresco-using-activiti-step-by-step/">this step-by-step tutorial</a>? As far as I see, it covers everything from processdefinition to a working UI. Of course it uses Activiti, which should really be given precedence to using the legacy JBPM engine, especially if you are starting fresh on Alfresco.

Regards
Axel

mwarme
Champ in-the-making
Champ in-the-making
I haven't seen that particular tutorial.  I chose JBPM over Activi for two reasons:  Firstly, I have zero familiarity with eclipse and am not necessarily a skilled programer, and more importantly, I COULD NOT find well-documented examples with either workflow engine, although the jbpm cookbook "recipes" I found typically had more well-documented examples that allowed me to actually understand what individual files required.  I have a few more weeks to try and get this done and I've now devoted a significant amount of time to trying to make the JBPM option work.  I'll read through this tutorial and see if it makes life easier, but my general experience thus far with alfresco has been a severe lack of good, well-organized documentation and lots of frustration.

afaust
Legendary Innovator
Legendary Innovator
Okay, if you want to stick with jBPM, the <a href="http://ecmarchitect.com/images/articles/alfresco-workflow/advanced-workflow-article.pdf">Developer Series - Advanced Workflow</a> guide from Jeff Potts may be one of the best sources.

Regards
Axel

mwarme
Champ in-the-making
Champ in-the-making
After spending a few more days wrestling with Alfresco, I'm still coming up short.  I have managed to put together a workflow-context.xml, a process model, a process definition, a workflow-messages.properties, and a web-client-config-custom.xml that don't prevent the alfresco explorer server from starting.  However, I can not for the life of me get my workflow visible as an option in the list of advanced workflows when I try to "start advanced workflow".  I'm not even sure exactly what file is responsible for a workflow being visible in the list, and my attempts to find out have been seemingly fruitless.  I assume it's the web-client-config-custom.xml file, but I have been unable to figure out what I'm doing wrong.  The workflow has been deployed with the workflow console–"deploy jbpm /tomcat/shared/classes/alfresco/extension/*workflow definition filename*", so I can't for the life of me figure out why it isn't showing up in the list of advanced workflows.

afaust
Legendary Innovator
Legendary Innovator
Hello,

the following conditions need to be met in order for workflows to be visible in the Web Client "Start Workflow" wizard:
<ol>
<li>the workflow engine needs to be enabled (i.e. property "system.workflow.engine.jbpm.enabled" set to true)</li>
<li>the workflow engines workflow definitions need to be visible (i.e. property "system.workflow.engine.jbpm.definitions.visible" set to true)</li>
<li>the workflow definition needs to be deployed into the engine</li>
</ol>

From your posts I gather conditions #1 and #3 are met. What about #2?

Regards
Axel

mwarme
Champ in-the-making
Champ in-the-making
Well, I'm very positive condition 2 is not met as it isn't mentioned in ANY of the documentation I've read, so I will test that and see if it works.

afaust
Legendary Innovator
Legendary Innovator
#2 is not mentioned in any JBPM related documentation since this condition did not exist when JBPM was the main / only workflow engine in Alfresco. I haven't checked current documentation, but was able to find a <a href="http://forums.alfresco.com/forum/developer-discussions/workflow/activiti-vs-jbpm-10052011-0837">forum post by Jan Pfitzner</a> on this topic. This is not a configuration option used very often - mostly just for backwards compatible upgrades of existing Alfresco installations.

mwarme
Champ in-the-making
Champ in-the-making
yes, it worked.  Thank you very much sir!