How: Which BPM Client Properties to be used for Different JBoss EAP Versions
Fact: Fujitsu Interstage BPM (Business Process Manager) Version 11.3.1
Fact: JBoss EAP (Enterprise Application Platform) Version 5.1.0
Fact: JBoss EAP Version 6.1.0
Fact: Fujitsu Interstage BPM Model API Version 11.3.1
Symptom:
BPM client session fails to login to server due to the following error:
"javax.naming.CommunicationException: Could not obtain connection to any of these urls: interstagedemo:1100 and discovery failed with error: javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out]",
"javax.naming.CommunicationException: Failed to connect to server interstagedemo/192.168.188.135:1100",
"javax.naming.ServiceUnavailableException: Failed to connect to server interstagedemo/192.168.188.135:1100",
"java.net.ConnectException: Connection refused: connect"
Fix:
The connection issue between Interstage BPM client and server can be caused by various reasons. In this article, the issue is caused by the usage of the wrong client properties, especially NamingProviderURL and JMSNamingProviderURL properties.
Specifically, the set of BPM client properties to be used is based on the JBoss EAP version used. In BPM v11.3.1, JBoss EAP v5.1.0 or v6.1.0 can be used. To be sure of the client properties to be loaded to your client application, look up your BPM server host for iFlowClient.properties file, typically found in {BPM deployment home}\engine\client\iFlowClilent.properties.
If JBoss EAP 6.1.0 is used, then the following set of client properties should be used:
//--------------------------------------------------------------------------------------------------
#IBPM Server Properties
#Mon Nov 09 13:48:39 PST 2015
AnalyticMissedEventProvider=ejb\:fujitsu-ibpm-engine/fujitsu-ibpm-engine-ejb/MissedEventProvider\!com.fujitsu.ibpm.analytics.eventretrieval.MissedEventProviderRH
HostName=WIN-C7VO9F9UF3H
JMSCommandTopic=jms/topic/CommandTopic
JMSEmailNotificationTopic=jms/topic/EmailNotificationTopic
JMSFactory=jms/iFlowConnectionFactory
JMSNamingProvider=org.jboss.naming.remote.client.InitialContextFactory
JMSNamingProviderURL=remote\://WIN-C7VO9F9UF3H\:4447
JMSNotificationTopic=jms/topic/NotificationTopic
JMSResponseTopic=jms/topic/ResponseTopic
JMSSQNotificationTopic=jms/topic/SQNotificationTopic
JMSSpecifications=JMS1.1
JmsFilterEnabled=false
NamingProvider=org.jboss.naming.remote.client.InitialContextFactory
NamingProviderURL=remote\://WIN-C7VO9F9UF3H\:4447
NumberOfDispatcherThread=1
TWFTransportType=EE
TenantName=Default
UserAgentServiceName=ejb\:fujitsu-ibpm-engine/fujitsu-ibpm-engine-ejb/UserAgentService\!com.fujitsu.iflow.serveree.intf.UserAgentServiceSH
//--------------------------------------------------------------------------------------------------
If JBoss EAP v5.1.0 is used, the following set of client properties should be used:
//--------------------------------------------------------------------------------------------------
#IBPM Server Properties
#Wed Sep 10 20:15:46 PDT 2014
HostName=WIN-C7VO9F9UF3H
JMSCommandTopic=iflow.CommandTopic
JMSEmailNotificationTopic=iflow.EmailNotificationTopic
JMSFactory=ConnectionFactory
JMSNamingProvider=org.jnp.interfaces.NamingContextFactory
JMSNamingProviderURL=jnp\://WIN-C7VO9F9UF3H\:1100
JMSNotificationTopic=iflow.NotificationTopic
JMSResponseTopic=iflow.ResponseTopic
JMSSQNotificationTopic=iflow.SQNotificationTopic
JMSSpecifications=JMS1.1
JmsFilterEnabled=false
NamingProvider=org.jnp.interfaces.NamingContextFactory
NamingProviderURL=jnp\://WIN-C7VO9F9UF3H\:1100
NumberOfDispatcherThread=1
TWFTransportType=EE
TenantName=Default
UserAgentServiceName=iflow.UserAgentService
//--------------------------------------------------------------------------------------------------
Thus, depending on which JBoss EAP version is used for the BPM server deployment, you will choose one of the two provided sample client properties for initializing the BPM session object. Just remember to update the hostname as highlighted in yellow to reflect the hostname in which JBoss EAP is running. Refer to model API documentation that concerns loading the BPM client properties:
//--------------------------------------------------------------------------------------------------
com.fujitsu.iflow.model.workflow.WFSession interface, method
void initForApplication(java.lang.String[] args, java.util.Properties prop) throws WFInternalException
Initializes a WFSession object for use within an application. It must be the first method called on WFSession when used in an application.
The properties which are necessary to initialize the session are stored in the "iFlowClient.properties" file of your Interstage BPM installation.
Specify log in tenant name of server via a new property key of TenantName. Default value of "Default" is used when none of TenantName is specified.
Parameters:args - The set of command-line parameters used in the application.prop - A persistent set of properties consisting of a table of keys and their corresponding values, stored as strings.
Throws:WFInternalException
//--------------------------------------------------------------------------------------------------