Workflows in InfoGlue


OBS: Before you read further: We will rewrite the workflow system in InfoGlue so we do not recommend implementing new workflows on the OSWorkflow engine.This chapter tries to give an introduction to how one creates new workflows.


Introducing the My Desktop Tool

In InfoGlue there is a tool called My Desktop which foremost is the center for workflow activity. The interface looks like this:

The areas are:

  • Ongoing workflows -Marked with red border. Shows the workflows that are currently active. In 2.1 of InfoGlue one can set up if only to show workflows belonging to one self or all active workflows. It is possible to from the workflows set the name shown there, default is simply the workflow name. Next to the name are buttons representing functions available. For example stopping and aborting the workflow is done there. Left to the name is an information button that letÆs you see how far the workflow has come.
  • Available workflows - Marked with blue border. Shows all available workflow definitions that can be started. Left to the workflow name is an information button describing the steps in the workflow.
  • Workflow - the area marked with green. Shows workflow name followed by the step and finally the action waiting to be carried out. Can be filtered in 2.1 so you only see steps you own.

OSWorkflow - The Workflow Engine

InfoGlue uses the OSWorkflow framework for all workflow handling. You should read the documentation on before beginning to build workflows.

Managing workflow definitions in InfoGlue

InfoGlue 2.0 introduces a new menu option in the Management tool. It is called Workflows and is where you enter all workflows that should be available in the My Desktop view. It looks like this:

To create a new workflow you press the ôNew Workflowö-button and end up in the editing view:

Here you enter a workflow definition name û it will be the one visible under the available workflows-list. Below the name in the "Workflow definition" you enter the xml-definition which is the OSWorkflow-instructions really. Just copy/paste it from your favourite XML-tool where you edit it and validated it before.

Creating workflows



Views are where you put the interfaces for the workflow. On each action that should have interaction you put the view attribute which can be a full URL or a relative URL. An example is:
<action id="20" name="Editera" view="workflows/gu_link_external_news/main.jsp">
Now here is a big design decision û either you can build your views as regular JSP-pages and put it as part of the CMS application. This is the most straight forward way and you get login, session and all InfoGlue API:s for free including a lot of ready made taglibs. Another solution is to build the views as pages in the delivery engine. This approach has its advantages if you have a big need to use texts and images entered in the tools. That is û you get your views content managed. On the other hand that way is not so tested by other projects.

The Property Set

This is by far one of the most important aspects of Workflow authoring. As workflow by definition does not hold state in memory over any longer period of time and those workflows often have a long duration one has limited options on data storing if OSWorkflow is going to keep track of it. OSWorkflow uses something called a Property Set which is basically a Map where you can persist objects with a string as the key identifying the object. The objects must be serializable and large objects are not encouraged to store that way.
The limitations this puts on us makes things like error handling, long transactions and similar issues more difficult and demands for a small framework helping us with all that. InfoGlue has some infrastructure for this.


As you will read in the OSWorkflow documentation there are prefunctions and results etc. to an action. From the workflow tool the My Desktop will send the user to the view first. When the view actually invokes the action upon user interaction (through the URL given to it) the prefunctions will get called first and then results-parts are evaluated and any post-functions get called last.

comments powered by Disqus