Oneway方式では、CORBAのサーバアプリケーションからの処理を待たずにシーケンス処理を継続することができます。
CORBAアダプタのサービスエンドポイント定義を作成します。CORBAのサーバアプリケーションを作成します。
Oneway方式で呼び出すことのできるCORBAのサーバアプリケーションは、sequence<octet>型のinパラメタを1つだけを持つ必要があります。
以下にOneway方式の場合のIDL定義例を示します。モジュール名、インタフェース名、データ名、および、メソッド名は任意となります。
module samplemodule { interface sampleinterface { // // Type declaration // typedef sequence<octet> binary; // // Message invoke // oneway void op1(in binary seq1); }; };
上記の定義は、それぞれ下記の設定としました。
項目 | 設定値 |
---|---|
モジュール名 | samplemodule |
インタフェース名 | sampleinterface |
データ名 | binary |
メソッド名 | op1 |
ネーミングサービスを設定します。
CORBAのサーバアプリケーションを呼び出すために、サーバアプリケーションのインプリメンテーションリポジトリへの登録とネーミングサービスにCORBAのサーバアプリケーションのオブジェクトリファレンスを登録しておく必要があります。
以下に実行例を示します。
OD_impl_inst -ax def OD_or_adm -c IDL:samplemodule/sampleinterface:1.0 -n samplemodule::sampleinterface
CORBAアプリケーション情報定義ファイル(def)の指定例
rep_id = IDL:samplemodule/sampleinterface:1.0 type = persistent lang = JAVA mode = SYNC_END proc_conc_max = 1 thr_conc_init = 16 ior = 1.1 locale = UNICODE
CORBAアダプタのサービスエンドポイント定義を作成します。
サービスエンドポイント定義の詳細にあるサーバアプリケーション情報のリクエスト方法でOneway方式を選択します。