WebSphere Message Broker バージョン 8.0.0.5 オペレーティング・システム: AIX、HP-Itanium、Linux、Solaris、Windows、z/OS

製品の最新バージョンについては、IBM Integration Bus バージョン 9.0 をご覧ください。

ローカル環境ツリーの Destination へのデータの取り込み

Destination サブツリーを使用して、出力ノード、HTTPRequest ノード、SOAPRequest ノード、SOAPAsyncRequest ノード、および RouteToLabel ノードで使用されるターゲット宛先をセットアップします。 以下の例は、ESQL プロシージャーを作成およびそれを使用して、それぞれの使用における値のセットアップというタスクを実行する方法を示しています。

これらのプロシージャーをコピーし、示されているとおりに使用するか、あるいはそれらを変更または拡張して同様のタスクを実行できます。

Compute ノード用にこの ESQL コードを作成しようとしている場合は、「計算モード」プロパティーを設定してこのノードを構成し、出力メッセージ内のローカル環境ツリーにアクセスできるようにしなければなりません。 「LocalEnvironment」「LocalEnvironment とメッセージ」、または「すべて」の 3 つの値のうち 1 つを選択しなければなりません。

宛先モード」プロパティーを「宛先リスト」に設定して、MQOutput ノードのキュー名を追加する
CREATE PROCEDURE addToMQDestinationList(IN LocalEnvironment REFERENCE, IN newQueue char) BEGIN
  /*******************************************************************************
  * A procedure that adds a queue name to the MQ destination list in the local environment.
  * This list is used by an MQOutput node that has its mode set to Destination list.
  *
  * IN LocalEnvironment: the LocalEnvironment to be modified. 
  * IN queue: the queue to be added to the list
  *
  *******************************************************************************/
DECLARE I INTEGER CARDINALITY(LocalEnvironment.Destination.MQ.DestinationData[]);
		IF I = 0 THEN
			SET OutputLocalEnvironment.Destination.MQ.DestinationData[1].queueName = newQueue;
		ELSE
			SET OutputLocalEnvironment.Destination.MQ.DestinationData[I+1].queueName = newQueue;
		END IF;
	END;
これらのエレメントの詳細については、MQ DestinationData サブツリー内のエレメントのデータ・タイプを参照してください。
SOAPRequest ノードまたは SOAPAsyncRequest ノードの要求のデフォルト URL の変更
CREATE PROCEDURE overrideDefaultSOAPRequestURL(IN LocalEnvironment REFERENCE, IN newUrl char) BEGIN
  /*******************************************************************************
  * A procedure that changes the URL to which the SOAPRequest node or 
  * SOAPAsyncRequest node sends the request.
  * 
  * IN LocalEnvironment: the LocalEnvironment to be modified. 
  * IN queue:  the URL to which to send the request.
  *
  *******************************************************************************/
SET OutputLocalEnvironment.Destination.SOAP.Request.Transport.HTTP.WebServiceURL = newUrl;
END;
HTTPRequest ノード要求のデフォルト URL の変更
CREATE PROCEDURE overrideDefaultHTTPRequestURL(IN LocalEnvironment REFERENCE, IN newUrl char) BEGIN
  /*******************************************************************************
  * A procedure that changes the URL to which the HTTPRequest node sends the request.
  * 
  * IN LocalEnvironment: the LocalEnvironment to be modified. 
  * IN queue: the URL to which to send the request.
  *
  *******************************************************************************/
  SET OutputLocalEnvironment.Destination.HTTP.RequestURL = newUrl;
END;
RouteToLabel ノードのラベルの追加
CREATE PROCEDURE addToRouteToLabelList(IN LocalEnvironment REFERENCE, IN newLabel char) BEGIN
  /*******************************************************************************
  * A procedure that adds a label name to the RouteToLabel list in the local environment.
  * This list is used by a RoteToLabel node.
  *
  * IN LocalEnvironment: the LocalEnvironment to be modified. 
  * IN label:  the label to be added to the list
  *
  *******************************************************************************/
	IF LocalEnvironment.Destination.RouterList.DestinationData is null THEN
     SET OutputLocalEnvironment.Destination.RouterList.DestinationData."label" = newLabel;
  ELSE
     CREATE LASTCHILD OF LocalEnvironment.Destination.RouterList.DestinationData
     NAME 'label' VALUE newLabel; 
  END IF;
END;
JMS 宛先リストのセットアップ
変換ノードによってローカル環境ツリー内に作成される宛先リストを使用して、JMSOutput ノードを、複数の JMS キューに送信するように、または複数の JMS トピックにパブリッシュするように構成することができます。 以下の例は、ローカル環境ツリーに JMS 宛先リストをセットアップする方法を示しています。
CREATE PROCEDURE CreateJMSDestinationList() BEGIN
  SET OutputLocalEnvironment.Destination.JMSDestinationList.DestinationData[1]  = 'jndi://TestDestQueue1';
  SET OutputLocalEnvironment.Destination.JMSDestinationList.DestinationData[2]  = 'jndi://TestDestQueue2';
  SET OutputLocalEnvironment.Destination.JMSDestinationList.DestinationData[3]  = 'jndi://TestDestQueue3';
END;
特記事項 | 商標 | ダウンロード | ライブラリー | サポート | フィードバック

Copyright IBM Corporation 1999, 2014Copyright IBM Corporation 1999, 2014.

        
        最終更新:
        
        最終更新: 2015-02-28 17:45:34


タスク・トピックタスク・トピック | バージョン 8.0.0.5 | ac16862_