12.18. IBM Websphere MQ インストールの検証
前提条件
- JBoss Enterprise SOA Platform の JMS プロバイダーとして事前設定された IBM Websphere MQ
手順12.9 タスク
- QM1 というキューマネージャーを作成します。crtmqm -q QM1
- runmqsc: runmqsc QM1を起動します。
- プロンプトが表示されたら、以下の設定を入力します。
define channel (CH.1) chltype (RCVR) trptype (TCP) start channel (CH.1) define qlocal (Q1) define listener(QM1.LISTENER) trptype(TCP) port(30001) ipaddr(10.12.58.110) start listener (QM1.LISTENER) (end) - プログラムを終了します。
com.ibm.mqetclient.jarを Websphere MQ インストールからサーバーにコピーします: cp com.ibm.mqetclient.jar SOA_ROOT/jboss-as/PROFILE/lib/- Wmq.jmsra.ivt.ear を Websphere MQ インストールからサーバーにコピー: cp
wmq.jmsra.ivt.earSOA_ROOT/jboss-as/server/PROFILE/deploy - Wmq.jmsra.rar を Websphere MQ インストールからサーバーにコピーします: cp
wmq.jmsra.rarSOA_ROOT/jboss-as/server/PROFILE/deploy - テキストエディターでデータソースファイルを作成します(IP アドレスを WSMQ サーバーのものに変更してください): vi SOA_ROOT/jboss-as/server/PROFILE/deploy/wsmq-ds.xml以下は、設定例です。
<?xml version="1.0" encoding="UTF-8"?> <connection-factories> <!-- connection factory definition --> <tx-connection-factory> <jndi-name>IVTCF</jndi-name> <xa-transaction /> <rar-name>wmq.jmsra.rar</rar-name> <connection-definition> javax.jms.ConnectionFactory </connection-definition> <config-property name="channel" type="java.lang.String">SYSTEM.DEF.SVRCONN</config-property> <config-property name="hostName" type="java.lang.String"> 10.12.58.110 </config-property> <config-property name="username" type="java.lang.String">mqm</config-property> <config-property name="password" type="java.lang.String">mqm</config-property> <config-property name="port" type="java.lang.String">30001</config-property> <config-property name="queueManager" type="java.lang.String">QM1</config-property> <config-property name="transportType" type="java.lang.String">CLIENT</config-property> <security-domain-and-application>JmsXARealm</security-domain-and-application> </tx-connection-factory> <!-- admin object definition --> <mbean code="org.jboss.resource.deployment.AdminObject" name="jca.wmq:name=ivtqueue"> <attribute name="JNDIName"> IVTQueue </attribute> <depends optional-attribute-name="RARName"> jboss.jca:service=RARDeployment,name='wmq.jmsra.rar' </depends> <attribute name="Type">javax.jms.Queue</attribute> <attribute name="Properties"> baseQueueManagerName=QM1 baseQueueName=Q1 </attribute> </mbean> </connection-factories> - ファイルを と
して保存し、テキストエディターを終了します。 - Web ブラウザーを起動し、にアクセスし http://localhost:8080/WMQ_IVT/ ます。これにより、IVT ("Install Verification Test")が起動します。
- 通常のテストとトランザクションテストを実行します。注記