Troubleshooting Assemble flow
Consult this article if you encounter problems using Assemble flow.
There are various utilities and methods you can use to determine flow status and exception types and locate problems. The following sections of this article describe methods for problem determination.
Checking output variables of activities
Assemble flow provides a simple Web interface to indicate runtime status of flow instances for developers. This feature is available when you add the zero.assemble.flow.management dependency to your application.
Point your browser to http://localhost:8080/flowadmin for monitoring flow instances. The following operations are supported:
- Click the flow ID link under the flow URI for toggling a variable list of this flow instance.
- Click the details link to get full details of the XML variable.
- Click the flow URI link to look for flow definition, as shown in the following example:
When the exception page is displayed
During the flow execution, the exception page (error page) is returned when the unhandled exception is thrown. The problem might be due to the following possibilities:
- Parsing error
- Examples include: illegal flow definition file, missing the required attribute of activity, syntax error in expression language.
- Runtime error
- Examples include: exception in the expression language, failed to access the REST resource, missing the reply activity.
You can specify the following line to enable the error page with detail exception information.
# Runtime mode (default is "production") /config/runtime/mode="development"
For example, in the Creating a simple extension activity tutorial, if toDouble() is not present for the rev.currency[0] variable in the <input/> Groovy expression of the rpy activity, then the following runtime exception information tells that data is not matched in type in activity rpy:
Therefore, the following events occur:
- Runtime exception occurs.
- Exception is located in activity
rpy. - Exception is caused by the unmatched data type for Groovy method
java.lang.Double.multiply().
Exception java.net.BindException is thrown in Windows platform
When you use Assemble flow to access the REST resources, you might see some java.net.BindException exceptions in the Windows™ platform.
By default, settings in Windows platform, the ephemeral ports, that Assemble flow opens for outgoing connections, are allocated to port numbers 1024 through 5000. You can increase the max port number to mitigate such problems by modifying or adding the MaxUserPort key under HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters.
For more information, see the following URL: http://technet2.microsoft.com/windowsserver/en/library/730fb465-d402-4853-bacc-16ba78e9fcc01033.mspx?mfr=true.
Using a proxy to access REST resources
The proxy server could be helpful for internet connections. You can also leverage the caching proxy to optimize the performance for REST resource accessing.
The Assemble flow engine leverages the IBM® WebSphere® sMash Connection API to access REST resources. You can add the following lines in your zero.config file to enable the proxy for all outgoing HTTP connections.
/config/connection/defaults/http/proxyHost = "proxyserver" /config/connection/defaults/http/proxyPort = "3128"
See the information about configuration of HTTP and HTTPS protocols for details.