Network Deployment (Distributed operating systems), v8.0 > Reference > Troubleshoot tips
Default messaging provider: Troubleshooting tips
Use this set of specific tips to help you troubleshoot problems for JMS messaging with the default messaging provider.
For general tips about troubleshooting problems with WAS messaging, see Messaging troubleshooting tips. This topic provides additional tips specific to the default messaging provider and its use of service integration technologies.
- A destination becomes full and can no longer receive messages because the existing messages are not being consumed.
- A JMS application can no longer send or receive messages
- JMS client applications running inside the Java EE client container fail when invoking the ConnectionFactory.createConnection method
A destination becomes full and can no longer receive messages because the existing messages are not being consumed.
When you configure an application to use the default messaging provider, you associate it with either of the following resource sets:
- One or more message beans connected through Java Message Service (JMS) activation specifications.
- One or more enterprise beans connected through JMS connection factories and JMS destinations.
We can use the following administrative console panel to inspect the configuration of the applications and JMS resources that are using the destination: Application resources for this destination.
This panel can help you find the cause of the problem by giving you a high level view of many relevant resources.
A JMS application can no longer send or receive messages
When you configure an application to use the default messaging provider, you associate it with either of the following resource sets:
- One or more message beans connected through Java Message Service (JMS) activation specifications.
- One or more enterprise beans connected through JMS connection factories and JMS destinations.
You connect the application to the message beans or enterprise beans through the application's deployment descriptor or through code in the application itself. If you connected the application through the deployment descriptor, you can use the following admin console panel to view the installed business application as whole and inspect the configuration of the JMS resources that are being used by the application: Messaging resources for this application.
This panel can help you find the cause of the problem by giving you a high level view of many relevant resources.
JMS client applications running inside the Java EE client container fail when invoking the ConnectionFactory.createConnection method
When a JMS client application is running inside the Java EE client container, on a machine that is running no other WAS processes, a call to the ConnectionFactory.createConnection method can fail with the following error:
CWSIJ0005E: An instance of the channel framework service to use for communication cannot be found.
Cause
The ConnectionFactory for the default messaging provider has a dependency on the Channel Framework Service. It locates the Channel Framework Service using a lookup in the JNDI namespace.
To connect to a naming service, the ConnectionFactory uses an InitialContext object created by using the default constructor.
When the JMS client is running within an application server environment, the InitialContext object is able to successfully connect to the naming service, the Channel Framework Service is located and the call to createConnection completes successfully.
However, when the JMS client is executing within the Java EE client container, the InitialContext object uses the value of the java.naming.provider.url system property, to determine the location of the naming service to connect to. If no value is specified for this property, it attempts to connect to a naming service located at port 2809 on the local client machine. If there is no server running on the client machine, there is no naming service listening on this port on the local machine. This causes the createConnection method to fail.
Solution
A JMS client application can specify the value of the java.naming.provider.url programmatically, by using code of the form:
String key = "java.naming.provider.url"; String value = "iiop://some.remote.machine:9810"; System.setProperty(key, value);This code should be run prior to invoking the createConnection method on the ConnectionFactory object.
Alternatively, if you use the launchClient script from the command line to start the Java EE client container, you can specify either of the following command line parameters:
- launchClient <CLIENT EAR> -CCBootstrapHost=some.remote.machine -CCBootstrapPort=981
- launchClient <CLIENT EAR> -CCproviderURL=iiop://some.remote.machine:9810
This ensures that if no provider URL is specified programmatically, then any InitialContext objects default to using the provider URL specified on the command line.
Application resources for this destination
Messaging resources for this application