プライマリ・コンテンツに移動
Oracle® Fusion Middleware Oracle Reports ServicesレポートWeb公開ガイド
12c (12.2.1.2)
E82763-01
  ドキュメント・ライブラリへ移動
ライブラリ
製品リストへ移動
製品
目次へ移動
目次
索引へ移動
索引

前
 
次
 

19.4 RWWebServiceUtilを使用したRWWebServiceのテスト

Oracle Reportsのインストールには、サンプルRWWebServiceUtil Webサービス・テスト・ユーティリティ・クラスが用意されています。これはORACLE_HOME /reports/jlib/rwrun.jarにあります。RWWebServiceUtilを使用して、RWWebServiceがサポートする様々な処理をテストできます。

このユーティリティの使用に必要な手順は、次のとおりです。

  1. クラスパスにrwrun.jarを追加します。

  2. 次のようにRWWebServiceUtilを通常のJavaプログラムとして実行します。

    $ORACLE_HOME\jdk\bin\java oracle.reports.rwclient.RWWebServiceUtil

  3. 次のような使用状況が表示されます。

    -endpoint       url of the webservice
    -method         web service operation to invoke
    
    runJob,getJobInfo,getServerInfo,killJob,getAPIVersion
     
       Input Parameters for runJob
        -cmdline        command line to be used while submitting the job
        -sync           boolean value to specify if job should be submitted
                        in synchronous manner or asynchronous manner
     
       Input Parameters for getJobInfo
        -server         server to be used for processing the request
        -jobid          jobid in numeric format
        -authid         user/password for authentication, if server is secure
     
       Input Parameters for getServerInfo
        -server         server to be used for processing the request
        -authid         authid for authentication, if server is secure
     
       Input Parameters for killJob
        -server         server to be used for processing the request
        -jobid          jobid in numeric format
        -authid         authid for authentication, if server is secure
    
  4. このユーティリティを使用すると、次のコマンドを使用してReports Serverにジョブを送信できます。

    $ORACLE_HOME\jdk\bin\java
    oracle.reports.rwclient.RWWebServiceUtil -endpoint
    http://yourmachine:port/reports/rwwebservice -method runjob -cmdline
    "report=test.rdf desformat=pdf destype=file desname=/tmp/output.pdf
    server=ReportsServer" -sync true
    
  5. これにより、リクエストがサーバーに送信され、SOAPレスポンスが次の書式で返されます。

    <?xml version = '1.0' encoding = 'UTF-8' standalone = 'yes'?>
       <serverQueues>
          <job id="2" queueType="past">
             <name>/home/vnanda/test.rdf</name>
             <type>report</type>
             <status code="4">Report  finished successfully.</status>
             <owner>RWUser</owner>
             <server>reportsserver</server>
             <destination>
                <desType>file</desType>
                <desName>/tmp/output.pdf</desName>
                <desFormat>pdf</desFormat>
                <file>output1.pdf</file>
             </destination>
             <timingInfo>
                <queued>Feb 17, 2009 9:41:36 AM</queued>
                <started>Feb 17, 2009 9:41:36 AM</started>
                <finished>Feb 17, 2009 9:41:38 AM</finished>
             </timingInfo>
          </job>
       </serverQueues>
    
  6. 同様に、RWWebServiceUtilを使用してRWWebServiceに対する他の処理も起動できます。