View JMS bindings on references and services of SCA composites
We can view information on a Java Message Service (JMS) binding for a Service Component Architecture (SCA) composite. Use scripts for viewing composition units in business-level applications. The scripts display information on settings of a binding.jms element.
An SCA composite that uses JMS bindings must be a composition unit in a business-level application. To view settings for a JMS binding on references, the composite must have defined a JMS binding in the reference. Similarly, to view settings for a JMS binding on services, the composite must have defined a JMS binding in the service.
After deployment of an SCA composite that uses JMS bindings, we can view the JMS binding settings. For information on the settings, refer to JMS binding settings for SCA composites or Section 1.4 of the SCA JMS Binding specification, Version 1.00.
- Start the wsadmin scripting tool.
- Optional: View online help for the viewCompUnit command.
Jython:
print AdminTask.help('viewCompUnit')
Using Jacl:
$AdminTask help viewCompUnit
- View all information on a composition unit, including information on any JMS binding settings.
Use the viewCompUnit command. The command has two parameters, -blaID and -cuID, both of type String.
Using Jython:
AdminTask.viewCompUnit('[-blaID myBLA -cuID myCompUnit]')
Using Jacl:
$AdminTask viewCompUnit {-blaID myBLA -cuID myCompUnit}
Variable Description $ is a Jacl operator for substituting a variable name with its value AdminTask is an object to run administrative commands with wsadmin.sh viewCompUnit is an AdminTask command myBLA is the configuration ID of the SCA business-level application myCompUnit is the configuration ID of the SCA composite composition unit
Results
After the viewCompUnit command runs, the product displays information on the composition unit, including information on references or services defined in the JMS binding of the SCA composite.
Example
Suppose that we have an SCA composite composition unit named myJmsBindingComposite that has defined JMS bindings and a business-level application named myJmsBLA containing the composition unit.
Run the viewCompUnit command to view information on the JMS binding settings.
- Jython:
AdminTask.viewCompUnit('[-blaID WebSphere:blaname=myJmsBLA -cuID WebSphere:cuname=myJmsBindingComposite]')
- Jacl:
$AdminTask viewCompUnit {-blaID WebSphere:blaname=myJmsBLA -cuID WebSphere:cuname=myJmsBindingComposite}
Running the viewCompUnit command displays information resembling the following on the JMS binding sections:
JMS Binding attributes (ReferenceJMSBinding) Specify JMS binding attributes for the composite defined in this SCA application. Correlation Schema (correlationSchema): [RequestMsgIDToCorrelID] Initial Context Factory (initialContextFactory): [com.ibm.websphere.naming.WsnInitialContextFactory] jndiURL (jndiURL): [iiop://localhost:2809] Request Connection (requestConnection): [myService] Response Connection (responseConnection): [myReference] Request Wire Format (requestWireFormat): [wireFormat.jmsTextXML] Response Wire Format (responseWireFormat): [wireFormat.jmsTextXML]JMS Binding Resources attributes (ReferenceJMSBindingResources) Specify JMS binding resource attributes for the composite defined in this SCA application. Component Name/Reference Name (resourceName): [myJMSFrontendComponent/helloWorldService] Destination Name (destinationName): [jms/SCA_JMS_Request1] Connection Factory Name (connectionFactoryName): [jms/SCA_JMS_CF] Destination Type (destinationType): [queue]JMS Binding Response Resources attributes (ReferenceJMSBindingResponseResources) Specify JMS binding response resource attributes for the composite defined in this SCA application. Component Name/Reference Name (resourceName): [myJMSFrontendComponent/helloWorldService] Response Destination Name (responseDestinationName): [jms/SCA_JMS_Response1] Response Connection Factory Name (responseConnectionFactoryName): [jms/SCA_JMS_CF] Response Destination Type (responseDestinationType): [queue] ...
What to do next
Examine the displayed information to ensure that the JMS binding settings are correct.
Edit the JMS binding resource and response resource JNDI name settings as needed using the editCompUnit command.
Related concepts
SCA composites
Related tasks
Edit JMS bindings on references and services of SCA composites Example: Create an SCA business-level application Manage composition units
BLAManagement (AdminTask)
Related information:
SCA JMS Binding specification