[V8.0.0.6 Jan 2017]

Installing and testing the resource adapter in WildFly

[V8.0.0.6 Jan 2017]If you are installing the IBM® MQ resource adapter in WildFly V10, you must first make some configuration file changes to add a subsystem definition for the IBM MQ resource adapter. You can then deploy the resource adapter and test it by installing and running the installation verification test (IVT) application.

About this task

Important: These instructions are for WildFly V10.

This task assumes that you have a running WildFly application server, and that you are familiar with standard administration tasks for it. This task also assumes that you have an IBM MQ installation and that you are familiar with standard administration tasks.

Procedure

  1. Create an IBM MQ queue manager called ExampleQM, and set it up as described in Preparing and running the sample programs.
    When setting up the queue manager, note the following points:
    • The listener must be started on port 1414.
    • The channel to be used is called SYSTEM.DEF.SVRCONN.
    • The queue used by the IVT application is named TEST.QUEUE.

    The model queue SYSTEM.DEFAULT.MODEL.QUEUE also needs to be granted DSP and PUT authority so this application can create a temporary reply queue.

  2. Edit the configuration file <WildFly_Home>/standalone/configuration/standalone-full.xml and add the following subsystem:
    <subsystem xmlns="urn:jboss:domain:resource-adapters:4.0">
        <resource-adapters>
            <resource-adapter id="wmq.jmsra">
                <archive>
                    wmq.jmsra.rar
                </archive>
                <transaction-support>NoTransaction</transaction-support>
                <connection-definitions>
                    <connection-definition class-name="com.ibm.mq.connector.outbound.ManagedConnectionFactoryImpl"
                                           jndi-name="java:jboss/jms/ivt/IVTCF" enabled="true" use-java-context="true"
                                           pool-name="IVTCF">
                        <config-property name="channel">SYSTEM.DEF.SVRCONN
                        </config-property>
                        <config-property
                                         name="hostName">localhost
                        </config-property>
                        <config-property name="transportType">
                            CLIENT
                        </config-property>
                        <config-property name="queueManager">
                            ExampleQM
                        </config-property>
                        <config-property name="port">
                            1414
                        </config-property>
                    </connection-definition>
                    <connection-definition class-name="com.ibm.mq.connector.outbound.ManagedConnectionFactoryImpl"
                                           jndi-name="java:jboss/jms/ivt/JMS2CF" enabled="true" use-java-context="true"
                                           pool-name="JMS2CF">
                        <config-property name="channel">
                            SYSTEM.DEF.SVRCONN
                        </config-property>
                        <config-property name="hostName">
                            localhost
                        </config-property>
                        <config-property name="transportType">
                            CLIENT
                        </config-property>
                        <config-property name="queueManager">
                            ExampleQM
                        </config-property>
                        <config-property name="port">
                            1414
                        </config-property>
                    </connection-definition>
                </connection-definitions>
            <admin-objects>
                <admin-object class-name="com.ibm.mq.connector.outbound.MQQueueProxy"
                              jndi-name="java:jboss/jms/ivt/IVTQueue" pool-name="IVTQueue">
                    <config-property name="baseQueueName">
                        TEST.QUEUE
                    </config-property>
                    </admin-object>
                </admin-objects>
            </resource-adapter>
        </resource-adapters>
    </subsystem>
  3. Deploy the resource adapter to your server by copying the wmq.jmsra.rar file into the directory <WildFly_Home>/standalone/deployments.
  4. Deploy the IVT application by coping the wmq.jmsra.ivt.ear file into the directory <WildFly_Home>/standalone/deployments.
  5. Start the application server, by bringing up a command prompt, navigating to the directory <WildFly_Home>/bin and running the command:
    standalone.bat -c standalone-full.xml
  6. Run the IVT application.
    For more information, see The installation verification test program for the IBM MQ resource adapter. For WildFly, the default URL is http://localhost:8080/WMQ_IVT/.