Process instance graph on a custom portlet


How can I show on my own portlet view the process instance graph?
I tried to use the portlet include with portlet /portlet/wm_process_graph___processgraph but it keeps throwing an error.
The error is misleading because I can see the process instance if I follow the usual path on MWS: Monitoring -> Business -> Process Instances.


java.sql.SQLException: Process Instance 04a7c432-4b9c-422d-ac71-faa047f06a9a not found
at com.webmethods.bpm.process.impl.db.common.LoadProcess.executeQuery(
at com.webmethods.portal.service.sql.core.BaseSqlWorker.executeQueryProcResult(
at com.webmethods.portal.service.sql.core.BaseSqlWorker.executeQueryProcResult(
at com.webmethods.bpm.process.impl.BpmProcess.load(
at com.webmethods.bpm.process.impl.BpmProcessManager.getProcess(
at com.webmethods.caf.processgraph.ProcessGraphDefaultviewView.getBpmProcess(
at com.webmethods.caf.processgraph.ProcessGraphDefaultviewView.getAnnotationJS(
at sun.reflect.GeneratedMethodAccessor1929.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
at java.lang.reflect.Method.invoke(
at javax.el.BeanELResolver.getValue(
at javax.el.CompositeELResolver.getValue(
at com.sun.faces.el.FacesCompositeELResolver.getValue(
at com.sun.el.parser.AstValue.getValue(
at com.sun.el.ValueExpressionImpl.getValue(
at com.sun.faces.application.ValueBindingValueExpressionAdapter.getValue(
at com.webmethods.caf.faces.application.CAFValueBinding.getValue(
at javax.faces.component.ValueExpressionValueBindingAdapter.getValue(
at javax.faces.component.UIOutput.getValue(
at com.webmethods.caf.faces.render.BaseRenderer.getValue(
at com.webmethods.caf.faces.render.html.output.ScriptRenderer.writeSrc(
at com.webmethods.caf.faces.render.html.output.ScriptRenderer.encodeEnd(
at javax.faces.component.UIComponentBase.encodeEnd(
at com.webmethods.caf.faces.component.util.ComponentUtils.renderComponent(
at com.webmethods.caf.faces.component.util.ComponentUtils.renderComponent(
at com.webmethods.caf.faces.view.BaseViewHandler.renderResponse(
at com.webmethods.caf.faces.view.BaseViewHandler.renderView(
at com.webmethods.caf.faces.portlet.PortletLifecycle$RenderResponsePhase.execute(
at com.webmethods.caf.faces.portlet.PortletLifecycle.phase(
at com.webmethods.caf.faces.portlet.PortletLifecycle.render(
at com.webmethods.caf.faces.portlet.FacesPortlet.render(

What you are attempting to do should work, but the Monitor team doesn’t support this usage pattern. In other words, they don’t document what parameters need to be set on the portlet in order for it to be rendered. Additionally, no testing has occurred where they determine if their portlets can be embedded into custom CAF Applications.

If I needed to embed their portlet, i would go to an instance of their portlet that is functioning, and try to determine all of that portlets properties. One way to do that would be to save that portlet to a workspace, and then using the Admin View in Designer, examine all the properties of the portlet.

However, I haven’t tried this myself and I know the Monitor team hasn’t attempted this.



Although I followed your advice I’m still facing the same problem.
Is there an official approach on how to show the process diagram on a custom portlet?


No there isn’t an official approach. I’m sorry to hear that the experiment wasn’t successful.



thanks Mark.

In the meantime I was able to go a little further (by using another portlet: wm_bam_instance___image) and now I don’t get the error. But, I still don’t don’t see the process.

I have compared both my custom portlet and a working version of the wm_bam_instance___image portlet added into a workspace and the html is different.

I have attached the the div part were they differ. Check lines 33.
It seems the flash object on the bad one is simply missing!

Any ideas?

bad.txt (3.3 KB)
good.txt (2.95 KB)


One step further: it wasn’t loading the flash because the parent hideable panel had the lazy load feature enabled.

Now, I’m including the portlet within my custom portlet by using the “portlet include” control with the following parameters:
-> instanceId
-> modelId
-> deployVersion
-> modelType
-> endpointUrl

All these fields are correctly set.
While loading the portlet, MWS calls 2 web services: getProcessModelXML and getImageInfo but the first one (getProcessModelXML) fails because modelId input field is null. This is odd because the field is also used for the second web service and in that case the field is set!

Any help?

I think I figured out why your portlet inclusion of the process image portlet does not work. I think the BAM image portlet has an internal defect in how handles bindings to the web service connectors: it manages bindings to getProcessImage in the right way, but fails to do properly for getProcessXML.

The reason the portlet works in the standard page is because, when these bindings fail, the resolution goes to GET parameters passed in the URL. Just take the example you are attempting now, and add to it a GET parameter “?modelId=”. It should work.

Hence, a way of solving this is, when a new modelId is entered, do a redirect from inside an action, so that the URL is rewritten to include this modelId. I am including an example of this, which is composed of:
-A portlet (showProcessModelP2) that incudes the process image one
-A MWS page (public folder) that in turn includes the showProcessModelP2 portlet, and binds to it the global configuration of Monitor for the IS URL. Currently I am binding this configuration to Folders > My webMethods Applications > Fabric Tasks > Administration > My webMethods > System Settings > Servers > System Settings , and then the monitorEndpointUrl property. However I actually do not know whether this setting is right, whether it works, or whether by default it just takes localhost:5555, because at runtime it just shows “”. However, if you need other value, you can use e.g. environment variables to configure it.

I am enclosing both the Designer project and the deployable war file, which includes the creation of the page (public folder) and the alias, so after deploying it you can go straight to /myShowProcessModel2 and see the portlet. Please use the Administrator account, since I suspect it will only work if the current MWS user has permissions in IS to call these services.

Hope this helps. Best regards (19.3 KB)

Hi Javier,

just to tell you that it worked.
thanks a lot.


Thax.this post helps alot.But Administrator only can now see the process graph ,no other project specific user can see this.Any permission I need to add that any project specific user can see the same.
This is urgent requirement.

I tried displaying process instance image on 8.2 by providing 3 parameters instanceId, modelId, deployVersion to portlet /portlet/wm_bam_instance___image inside portletInclude control but it gives binding error -->Failed to evaluate binding expression: “#{activePageBean.drilldownJS}”. Is there anyway to get hold of source code of system portlet or am i missing something because i gave all necessary permission to user to view business process and added them to monitor Administrator ACL and monitor user ACL. Any pointer would be of great help.

Thanks in advance.

You may use the generateInstanceImage service. The service returns an IS url.

Hope this help.