Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

Anchor
top
top

 


こちらで紹介するwebサービスの呼び出しは、コンテンツのエクスポートとインポートに関連しています。webサービスAPIは現在、以下のタイプのコンテンツのエクスポートとインポートを制限しています。

    • レポート
    • レポートカテゴリー
    • レポートサブカテゴリー
    • データソース
    • ビュー
    • ダッシュボード
    • トランスフォーメーションフロー

...


エクスポートwebサービス


こちらのプロセスは、エクスポート可能な情報を取得し、他のサービスで再利用するために、エクスポートwebサービスを実行する方法を紹介します。こちらのプロセスは、エクスポート可能な情報を取得し、他のサービスで再利用するための、エクスポートwebサービスを実行する方法を紹介します。エクスポート可能なすべてのYellowfinコンテンツを取得するためには、GETCONTENT関数を使用します。これは、すべてをエクスポートする場合にも役立ちます。


  1. エクスポート可能なすべてのYellowfinコンテンツを取得するためには、GETCONTENT関数を使用します。これは、すべてをエクスポートする場合にも便利です。

こちらの関数は、Yellowfinコンテンツの詳細を含む、ContentResourceオブジェクトの配列を返し、これは他の呼び出しで詳細をインポート、エクスポート、検証するために再利用することができます。

独自のエクスポート一覧を構成し、コンテンツ定義をContent Resourceオブジェクトに配置することもできます。オブジェクト定義は、各Yellowfinコンテンツに必要となる要素を明確にします。

Yellowfinの各コンテンツタイプで、オブジェクトのresorceType値を把握する必要があります。

すべてのコンテンツタイプの依存関係を手動で検索する代わりに、GETEXPORTDEPENDRNCIES関数を使用して、ContentResorceオブジェクトにその詳細を格納することで、依存関係が必要なコンテンツを指定します。

例えば、あるダッシュボードをエクスポートする場合、その特定のダッシュボードを表す単一のオブジェクトをContentResorceに含めることができます。この関数は、レポート、ビュー、データソース、カテゴリー、サブカテゴリーを含むダッシュボードの依存関係を返します(これらは、ContentResourceオブジェクト配列として返されます)

YellowfinコンテンツとともにXMLファイルを取得する場合は、複数のContentResorceオブジェクトの配列を作成し、EXPORTCONTENT関数を呼び出します。このファイルは、異なるYellowfinの環境にインポートすることもできます。

注意:GETEXPORTDEPENDENCIESとEXPORTCONTENT webサービスは、クライアント組織リソースで適切に機能しません。デフォルト組織リソースでのみ、これらの関数を使用して、適切にエクスポートすることができます。

 

 

 

...

  1. こちらの関数は、Yellowfinのコンテンツの詳細を含む、ContentResourceオブジェクトの配列を返します。これは、他の呼び出しで、詳細のインポートや、エクスポート、検証に再利用することができます。このオブジェクトの詳細については、オブジェクト定義を参照してください。
  2. 独自のエクスポート一覧を構成し、コンテンツ定義をContentResourceオブジェクトに配置することもできます。オブジェクト定義は、各Yellowfinのコンテンツに要求される要素を明確にします。
  3. Yellowfinの各コンテンツタイプで、オブジェクトのresorceType値を把握する必要があります。

    コンテンツタイプContentResource resourceType

    レポートカテゴリー

    RPTCATEGORY

    レポートサブカテゴリー

    RPTSUBCATEGORY

    データソース

    DATASOURCE

    ビュー

    VIEW

    ダッシュボード

    GROUP

    レポート

    REPORT

    データトランスフォーメーション

    ETLPROCESS


  4. すべてのコンテンツタイプの依存関係を手作業で検索する代わりに、GETEXPORTDEPENDRNCIES関数を使用して、ContentResourceオブジェクトにその詳細を保存することで、依存関係が必要なコンテンツを指定します。
  5. 例えば、あるダッシュボードをエクスポートする場合、その特定のダッシュボードを表す単一のオブジェクトをContentResourceに含めることができます。この関数は、レポート、ビュー、データソース、カテゴリー、サブカテゴリーを含むダッシュボードの依存関係を返します(これらは、ContentResourceオブジェクト配列に返されます)。
  6. YellowfinコンテンツとともにXMLファイルを取得する場合は、複数のContentResourceオブジェクトの配列を作成し、EXPORTCONTENT関数を呼び出します。このファイルは、異なるYellowfinの環境にインポートすることもできます。
  7. 注意:GETEXPORTDEPENDENCIESとEXPORTCONTENTのwebサービスは、クライアント組織のリソースでは適切に機能しません。これらの関数を使用して、適切にエクスポートができるのはデフォルト組織のリソースのみです。



主要なエクスポート関数

Expand
titleGETCONTENT

こちらの関数は、エクスポート可能なすべてのYellowfinコンテンツを返します。 


リクエストパラメーター

以下の要素は、こちらのリクエストとともに渡されます。

リクエスト要素データ型説明

LoginId

String

Yellowfin Webサービスの管理者ユーザーIDです。これは、ログインIDの方法に応じて、ユーザーID、または電子メールアドレスになります。

このYellowfinアカウントは、「Yellowfin Webサービス使用権」が有効化されたロールを持ち、デフォルト(プライマリー)組織に所属していなくてはいけません。

Password

String

上記アカウントのパスワードです。

OrgId

Integer

Yellowfin内のデフォルト(プライマリー)組織IDです。常に、「1」に設定します。

Function

String

Webサービス関数です。こちらは、「GETCONTENT」に設定します。

OrgRefStringこちらのオプションパラメーターは、クライアント組織IDを指定するために使用することができます。
 


リクエストの例

以下は、こちらのリクエストのSOAP XMLの例です。

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteAdministrationCall>
         <arg0>
          <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <function>GETCONTENT</function>          
         </arg0>
      </web:remoteAdministrationCall>
   </soapenv:Body>
</soapenv:Envelope>
 


応答パラメーター

返される応答には、これらのパラメーターが含まれます。

応答要素データ型説明

StatusCode

String

Webサービスの呼び出しのステータスです。値の選択肢は、以下の通りです。Webサービス呼び出しのステータスです。値の選択肢は、以下の通りです。

  • SUCCESS
  • FAILURE
ContentResorcesContentResourcesContentResorceContentResource[]エクスポート可能なYellowfinのコンテンツの詳細を含むオブジェクト配列です。

応答の例

サービスは、今回のSOAPの例に基づき、以下の応答を返します。

Code Block
languagexml
themeEclipselanguagexml
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteAdministrationCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
         <return>
            <contentResources>
               <resourceCode>AUDITREPORTS</resourceCode>
               <resourceDescription>Audit Reports</resourceDescription>
               <resourceId>56339</resourceId>
               <resourceName>Audit Reports</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTCATEGORY</resourceType>
               <resourceUUID>a6bdc6b5-a832-42a2-98c7-18273900d0aa</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>ADMINREPORTS</resourceCode>
               <resourceDescription>Admin Reports</resourceDescription>
               <resourceId>56340</resourceId>
               <resourceName>Admin Reports</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>f7fb32b7-1573-4899-916f-c34afb9a865d</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>CONTENTUSAGE</resourceCode>
               <resourceDescription>Content Usage</resourceDescription>
               <resourceId>56341</resourceId>
               <resourceName>Content Usage</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>6bae5230-c1f9-4491-8a8b-f14b1ae660d7</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>USERACCESS</resourceCode>
               <resourceDescription>User Access</resourceDescription>
               <resourceId>56342</resourceId>
               <resourceName>User Access</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>0c7ddde4-fa03-4e88-b37b-7b5e4aad5e1d</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>TUTORIAL</resourceCode>
               <resourceDescription>Tutorial</resourceDescription>
               <resourceId>60706</resourceId>
               <resourceName>Tutorial</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTCATEGORY</resourceType>
               <resourceUUID>a23c2ec6-a2fa-45c7-b5da-dcf3f02e6633</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>ATHLETES</resourceCode>
               <resourceDescription>Athletes</resourceDescription>
               <resourceId>60707</resourceId>
               <resourceName>Athletes</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>72e4b4bd-a482-4a01-a031-c6ab76dbb3a5</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>CAMP</resourceCode>
               <resourceDescription>Camp</resourceDescription>
               <resourceId>60708</resourceId>
               <resourceName>Camp</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>465411e5-594b-478e-af64-c0f59fc4546f</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>KPIS</resourceCode>
               <resourceDescription>KPIs</resourceDescription>
               <resourceId>60709</resourceId>
               <resourceName>KPIs</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>d514c643-dc01-4781-8905-d34e761ccd19</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>MARKETINGBOOKING</resourceCode>
               <resourceDescription>Marketing &amp; Booking</resourceDescription>
               <resourceId>60710</resourceId>
               <resourceName>Marketing &amp; Booking</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>dbe6d0a3-c088-4d71-b65a-f383aaa54be9</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>TRAINING</resourceCode>
               <resourceDescription>Training</resourceDescription>
               <resourceId>60711</resourceId>
               <resourceName>Training</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>c503ea57-cc69-43a9-98bc-a90ebbe1c864</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70101</resourceId>
               <resourceName>Oracle database</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70109</resourceId>
               <resourceName>Oracle</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription>Ski Team is the demonstration and tutorial database.</resourceDescription>
               <resourceId>54700</resourceId>
               <resourceName>Ski Team</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>54701</resourceId>
               <resourceName>Yellowfin Configuration Database</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70108</resourceId>
               <resourceName>c</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70110</resourceId>
               <resourceName>f</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription>This is a tutorial view for training and demo purposes.</resourceDescription>
               <resourceId>60543</resourceId>
               <resourceName>Ski Team</resourceName>
               <resourceType>VIEW</resourceType>
               <resourceUUID>e3632adb-5194-460c-a172-c085416f493f</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription>This view should be used to monitor usage of Yellowfin by User and Content Type.</resourceDescription>
               <resourceId>56169</resourceId>
               <resourceName>Yellowfin Usage Audit</resourceName>
               <resourceType>VIEW</resourceType>
               <resourceUUID>fb6416c4-441e-42b3-a442-e7426f25f6b4</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription>This dashboard contains a set of reports covering general system and admin information, including performance, sessions, data source &amp; view usage.</resourceDescription>
               <resourceId>57438</resourceId>
               <resourceName>Admin</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>GROUP</resourceType>
               <resourceUUID>33827292-cda6-4071-965f-730ccbc53519</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription>This is an analytic tab that is used to understand examine metrics split by various demographics and filters.</resourceDescription>
               <resourceId>61195</resourceId>
               <resourceName>Analysis</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>GROUP</resourceType>
               <resourceUUID>f19e63f5-7175-4c57-897d-ed865aba8972</resourceUUID>
            </contentResources>
            </contentResources>
            <errorCode>0</errorCode>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Web Service Request Complete</messages>
            <sessionId>92029c8ae4f1db0f33bf0b7370c1088a</sessionId>
            <statusCode>SUCCESS</statusCode>
         </return>
      </ns2:remoteAdministrationCallResponse>
   </S:Body>
</S:Envelope>
 


手順

Javaの例を使用して、こちらの呼び出しを実行するための詳細な手順は、以下を参照してください。

Expand
title詳細手順
  • 管理ユーザーとしてのログインと、実行するwebサービスの呼び出しの指定を含む、こちらの関数の基礎的なリクエストから開始します。

    Code Block
    languagejava
    themeEclipselanguagejava
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    rsr.setFunction("GETCONTENT");


  • 特定のクライアント組織を識別することもできます。


    Code Block
     code
    language
    java
    themeEclipse
    languagejava
    rsr.setOrgRef("org1");


  • リクエストを構成したら、呼び出しを実行します。

    Code Block
    languagejava
    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    管理サービスを初期化します。実行方法の詳細は、管理webサービスを初期化します。実行方法の詳細は、こちらを参照してください。

 


  • 返される応答には、次の要素が含まれます。:StatusCodeとContentResorce。(StatusCodeとContentResource。(より詳細な情報は、上記応答パラメーターの表を参照してください)

 



完成例

以下は、こちらのwebサービスの呼び出しの完成例です。こちらを使用するには、以下の手順に従います。

  1. コードをコピーして、「ws_getcontent.jsp」として保存します。
  2. root(Yellowfin/appserver/webapps/ROOT)フォルダーにファイルを配置します。
  3. 環境に応じて、ホスト、ポート番号、管理ユーザーの詳細を調整します。
  4. インターネットブラウザから、「http://<host>:<port>/ws_getcontent.jsp」を実行します。

Code Block
languagejava
themeEclipselanguagejava
<%      
/*      ws_getcontent.jsp               */
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%
  
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);       // adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
  
rsr.setLoginId("admin@yellowfin.com.au"); // provide your Yellowfin webservices admin account
rsr.setPassword("test");                                          // change to be the password of the account above
rsr.setOrgId(1);
rsr.setFunction("GETCONTENT");
  
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
            if ("SUCCESS".equals(rs.getStatusCode()) ) {
                        out.write("<br>Success");
                        ContentResource[] crs = rs.getContentResources();
                        out.write("<table>");
                        out.write("<tr><td> id </td><td> type </td><td> UUID </td></tr>");
                        for (ContentResource c: crs) {
                                    out.write("<tr>");
                                    out.write("<td>" + c.getResourceId() + "</td><td>" + c.getResourceType() + "</td><td>" + c.getResourceUUID() + "</td>");
                                    out.write("</tr>");
                        }
            }
            else {
            out.write("<br>Failure");
            out.write(" Code: " + rs.getErrorCode());
            }          
%>



<S
Expand
titleEXPORTCONTENT

こちらの関数は、

 こちらの関数は、選択したYellowfinのコンテンツを、XMLファイルにエクスポートします。


リクエストパラメーター

以下の要素は、こちらのリクエストとともに渡されます。

リクエスト要素データ型説明

LoginId

String

Yellowfin Webサービスの管理者ユーザーIDです。これは、ログインIDの方法に応じて、ユーザーID、または電子メールアドレスになります。

このYellowfinアカウントは、「Yellowfin Webサービス使用権」が有効化されたロールを持ち、デフォルト(プライマリー)組織に所属していなくてはいけません。

Password

String

上記アカウントのパスワードです。

OrgId

Integer

Yellowfin内のデフォルト(プライマリー)組織IDです。常に、「1」に設定します。

Function

String

Webサービス関数です。こちらは、「GETCONTENTEXPORTCONTENT」に設定します。

OrgRefStringこちらのオプションパラメーターは、クライアント組織IDを指定するために使用することができます。
 
ContentResourcesContentResourceエクスポートするコンテンツを指定するために使用するオブジェクトです。以下の表を参照してください。


以下のパラメーターは、こちらの関数を呼び出すためにContentResourceオブジェクトに指定します。

ContentResource要素データ型説明
ResourceIDIntegerコンテンツの内部IDを提供する必須パラメーターです。
ResourceTypeString

コンテンツタイプを指定する必須パラメーターです。選択肢は、以下の通りです。

  • RPTCATEGORY
  • RPTSUBCATEGORY
  • DATASOURCE
  • VIEW
  • GROUP
  • REPORT
  • ETLPROCESS
ResourceUUIDStringこちらのオプションパラメーターは、コンテンツのUUIDを提供するために使用することができます。


リクエストの例

以下は、こちらのリクエストのSOAP XMLの例です。

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteAdministrationCall>
         <arg0>
          <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <function>GETCONTENT<<function>EXPORTCONTENT</function>
            <contentResources>
        </arg0>       </web:remoteAdministrationCall><resourceId>56169</resourceId>
       </soapenv:Body>
</soapenv:Envelope>
 
        <resourceType>VIEW</resourceType>
            </contentResources>         
         </arg0>
      </web:remoteAdministrationCall>
   </soapenv:Body>
</soapenv:Envelope>


応答パラメーター

返される応答には、これらのパラメーターが含まれます。

応答要素データ型説明

StatusCode

String

Webサービスの呼び出しのステータスです。値の選択肢は、以下の通りです。

  • SUCCESS
  • FAILURE
ContentResorcesBinaryAttachmentsContentResorceReportBinaryObject[]エクスポート可能なYellowfinのコンテンツの詳細を含むオブジェクト配列です。エクスポート可能なYellowfinのコンテンツの詳細を含むオブジェクト配列です。以下の表を参照してください。
応答の例


ReportBinaryObject配列は、こちらの呼び出しに以下のパラメーターを返します。サービスは、今回のSOAPの例に基づき、以下の応答を返します。

ReportBinaryObject要素
code
データ型
theme
説明
Eclipse
Key
languagexml
Stringこちらの関数のバイナリーオブジェクト保存に一意のキーは、「EXPORT/XML」です。
ContentTypeStringこちらの関数のMIME型は「text/XML」です。
DataByte[]こちらの配列は、XMLファイルに保存可能なコンテンツのメタデータを含みます。



応答の例

サービスは、今回のSOAPの例に基づき、以下の応答を返します。

Code Block
languagexml
themeEclipse
<soapenv:Envelope xmlns:Ssoapenv="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteAdministrationCallResponse xmlns:ns2web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
 <return>     <web:remoteAdministrationCall>
       <contentResources>  <arg0>
          <loginId>admin@yellowfin.com.au</loginId>
  <resourceCode>AUDITREPORTS</resourceCode>          <password>test</password>
     <resourceDescription>Audit Reports</resourceDescription>      <orgId>1</orgId>
         <resourceId>56339</resourceId>   <function>EXPORTCONTENT</function>
            <resourceName>Audit Reports</resourceName><contentResources>
               <resourceOrgId>1<<resourceId>56169</resourceOrgId>resourceId>
               <resourceType>RPTCATEGORY<<resourceType>VIEW</resourceType>
               <resourceUUID>a6bdc6b5-a832-42a2-98c7-18273900d0aa</resourceUUID>
            </contentResources>         
   <contentResources>      </arg0>
         <resourceCode>ADMINREPORTS</resourceCode></web:remoteAdministrationCall>
               <resourceDescription>Admin Reports</resourceDescription>
               <resourceId>56340</resourceId>
               <resourceName>Admin Reports</resourceName>
               <resourceOrgId>1</resourceOrgId></soapenv:Body>
</soapenv:Envelope>


手順

Javaの例を使用して、こちらの呼び出しを実行するための詳細な手順は、以下を参照してください。

Expand
title詳細手順
  • 管理ユーザーとしてのログインと、実行するwebサービスの呼び出しの指定を含む、こちらの関数の基礎的なリクエストから開始します。

    Code Block
    languagejava
    themeEclipse
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    rsr.setFunction("EXPORTCONTENT");


  • オブジェクトを使用してエクスポートするコンテンツを指定します。


    Code Block
    languagejava
    themeEclipse
    ContentResource[] cr = new ContentResource[1];
    cr[0] = new ContentResource();
    cr[0].setResourceId(70058);
    cr[0].setResourceType("GROUP");
    cr[0].setResourceOrgId(1);


  • リクエストにオブジェクトを配置します。


    Code Block
    languagejava
    themeEclipse
    rsr.setContentResources(cr);


  • リクエストを構成したら、呼び出しを実行します。

    Code Block
    languagejava
    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    管理webサービスを初期化します。実行方法の詳細は、こちらを参照してください。


  • 返される応答には、次の要素が含まれます。:StatusCodeとReportBinaryObject。(より詳細な情報は、上記応答パラメーターの表を参照してください)


完成例

以下は、こちらのwebサービスの呼び出しの完成例です。こちらを使用するには、以下の手順に従います。

  1. コードをコピーして、「ws_exportcontent.jsp」として保存します。
  2. root(Yellowfin/appserver/webapps/ROOT)フォルダーにファイルを配置します。
  3. 環境に応じて、ホスト、ポート番号、管理ユーザーの詳細を調整します。
  4. インターネットブラウザから、「http://<host>:<port>/ws_exportcontent.jsp」を実行します。

Code Block
languagejava
themeEclipse
<%      
/*      ws_exportcontent.jsp   <resourceType>RPTSUBCATEGORY</resourceType>             */
%>
 <resourceUUID>f7fb32b7-1573-4899-916f-c34afb9a865d</resourceUUID>
            </contentResources>
            <contentResources>
       <%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%@ page import="java.nio.file.Files" %>
<%@ page import="java.io.PrintWriter" %>
<%
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);        <resourceCode>CONTENTUSAGE<//resourceCode> adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
<resourceDescription>Content Usage</resourceDescription> 
rsr.setLoginId("admin@yellowfin.com.au");              <resourceId>56341<//resourceId> provide your Yellowfin web services admin account
rsr.setPassword("test");        <resourceName>Content Usage</resourceName>                <resourceOrgId>1</resourceOrgId>   // set to the password of the above account
rsr.setOrgId(1);
rsr.setFunction("EXPORTCONTENT");
  
<resourceType>RPTSUBCATEGORY<//resourceType> specify which dashboard to export:
ContentResource[] cr = new ContentResource[1];
cr[0] = new ContentResource();
 <resourceUUID>6bae5230-c1f9-4491-8a8b-f14b1ae660d7</resourceUUID>
            </contentResources>
            <contentResources>cr[0].setResourceId(70058);
cr[0].setResourceType("GROUP");
cr[0].setResourceOrgId(1);
  
rsr.setContentResources(cr);
  
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
  
if ("SUCCESS".equals(rs.getStatusCode()) ) {
            out.write("<br>Success");
   <resourceCode>USERACCESS</resourceCode>         byte[] data = rs.getBinaryAttachments()[0].getData();
   <resourceDescription>User Access</resourceDescription>        String xml = new String(data, "UTF-8");
  <resourceId>56342</resourceId>          PrintWriter writer = new   <resourceName>User Access</resourceName>
PrintWriter("/Applications/Yellowfin 7.4/YFexport.xml", "UTF-8");
            writer.println(xml);
 <resourceOrgId>1</resourceOrgId>           writer.close();
    <resourceType>RPTSUBCATEGORY</resourceType>         
      <resourceUUID>0c7ddde4-fa03-4e88-b37b-7b5e4aad5e1d</resourceUUID>      ReportBinaryObject[] bo = rs.getBinaryAttachments();
   </contentResources>         for (ReportBinaryObject o  <contentResources>
  : bo){
            <resourceCode>TUTORIAL</resourceCode>            out.write("<br><br>Key: " +  <resourceDescription>Tutorial</resourceDescription>o.getKey());
                <resourceId>60706</resourceId>        out.write("<br>Content Type: "   + o.getContentType());
  <resourceName>Tutorial</resourceName>           }
    <resourceOrgId>1</resourceOrgId>         
  
} else {
<resourceType>RPTCATEGORY</resourceType>            out.write("Failure");
   <resourceUUID>a23c2ec6-a2fa-45c7-b5da-dcf3f02e6633</resourceUUID>         out.write(" Code: "  </contentResources>
            <contentResources>
               <resourceCode>ATHLETES</resourceCode>
               <resourceDescription>Athletes</resourceDescription>
               <resourceId>60707</resourceId>
               <resourceName>Athletes</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>72e4b4bd-a482-4a01-a031-c6ab76dbb3a5</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>CAMP</resourceCode>
               <resourceDescription>Camp</resourceDescription>
               <resourceId>60708</resourceId>
               <resourceName>Camp</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>465411e5-594b-478e-af64-c0f59fc4546f</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>KPIS</resourceCode>
               <resourceDescription>KPIs</resourceDescription>
               <resourceId>60709</resourceId>
               <resourceName>KPIs</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>d514c643-dc01-4781-8905-d34e761ccd19</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>MARKETINGBOOKING</resourceCode>
               <resourceDescription>Marketing &amp; Booking</resourceDescription>
               <resourceId>60710</resourceId>
               <resourceName>Marketing &amp; Booking</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>dbe6d0a3-c088-4d71-b65a-f383aaa54be9</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceCode>TRAINING</resourceCode>
               <resourceDescription>Training</resourceDescription>
               <resourceId>60711</resourceId>
               <resourceName>Training</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>RPTSUBCATEGORY</resourceType>
               <resourceUUID>c503ea57-cc69-43a9-98bc-a90ebbe1c864</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70101</resourceId>
               <resourceName>Oracle database</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70109</resourceId>
               <resourceName>Oracle</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription>Ski Team is the demonstration and tutorial database.</resourceDescription>
               <resourceId>54700</resourceId>
               <resourceName>Ski Team</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>54701</resourceId>
               <resourceName>Yellowfin Configuration Database</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70108</resourceId>
               <resourceName>c</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription/>
               <resourceId>70110</resourceId>
               <resourceName>f</resourceName>
               <resourceOrgId>1</resourceOrgId>
               <resourceType>DATASOURCE</resourceType>
            </contentResources>
            <contentResources>
               <resourceDescription>This is a tutorial view for training and demo purposes.</resourceDescription>
               <resourceId>60543</resourceId>
               <resourceName>Ski Team</resourceName>
               <resourceType>VIEW</resourceType>
               <resourceUUID>e3632adb-5194-460c-a172-c085416f493f</resourceUUID>
            </contentResources>
            <contentResources>
               <resourceDescription>This view should be used to monitor usage of Yellowfin by User and Content Type.</resourceDescription>
               <resourceId>56169</resourceId>
               <resourceName>Yellowfin Usage Audit</resourceName>
               <resourceType>VIEW</resourceType>
      + rs.getErrorCode());
}
%>



Expand
titleGETEXPORTDEPENDENCIES

こちらの関数は、特定のコンテンツのすべての依存関係を返します。ContentResourceオブジェクトは、リソースID(GETCONTENTの呼び出しを使用して取得することができます)とともにコンテンツを指定するために使用します。 例えば、レポートが定義されたコンテンツタイプであれば、応答にはレポートカテゴリー、サブカテゴリー、データソース、ビューなどの依存関係が表示されます。


リクエストパラメーター

以下の要素は、こちらのリクエストとともに渡されます。

リクエスト要素データ型説明

LoginId

String

Yellowfin Webサービスの管理者ユーザーIDです。これは、ログインIDの方法に応じて、ユーザーID、または電子メールアドレスになります。

このYellowfinアカウントは、「Yellowfin Webサービス使用権」が有効化されたロールを持ち、デフォルト(プライマリー)組織に所属していなくてはいけません。

Password

String

上記アカウントのパスワードです。

OrgId

Integer

Yellowfin内のデフォルト(プライマリー)組織IDです。常に、「1」に設定します。

Function

String

Webサービス関数です。こちらは、「GETEXPORTDEPENDENCIES」に設定します。

OrgRefStringこちらのオプションパラメーターは、クライアント組織IDを指定するために使用することができます。
ContentResourcesContentResource依存関係を取得するコンテンツのメタデータを含むオブジェクトです。以下の表を参照してください。


以下のパラメーターは、こちらの関数を呼び出すためにContentResourceオブジェクトに指定します。

ContentResource要素データ型説明
ResourceIDIntegerコンテンツの内部IDを提供する必須パラメーターです。
ResourceTypeString

コンテンツタイプを指定する必須パラメーターです。選択肢は、以下の通りです。

  • RPTCATEGORY
  • RPTSUBCATEGORY
  • DATASOURCE
  • VIEW
  • GROUP
  • REPORT
  • ETLPROCESS
ResourceUUIDStringこちらのオプションパラメーターは、コンテンツのUUIDを提供するために使用することができます。


リクエストの例

以下は、こちらのリクエストのSOAP XMLの例です。

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteAdministrationCall>
        <resourceUUID>fb6416c4-441e-42b3-a442-e7426f25f6b4</resourceUUID>
 <arg0>
           </contentResources><loginId>admin@yellowfin.com.au</loginId>
            <contentResources><password>test</password>
               <resourceDescription>This dashboard contains a set of reports covering general system and admin information, including performance, sessions, data source &amp; view usage.</resourceDescription>
  <orgId>1</orgId>
            <function>GETEXPORTDEPENDENCIES</function>
            <resourceId>57438</resourceId><contentResources>
               <resourceName>Admin<<resourceId>56169</resourceName>resourceId>
               <resourceOrgId>1<<resourceType>VIEW</resourceOrgId>resourceType>
            </contentResources>   <resourceType>GROUP</resourceType>      
         <resourceUUID>33827292-cda6-4071-965f-730ccbc53519</resourceUUID></arg0>
      </web:remoteAdministrationCall>
   </soapenv:Body>
 </contentResources>
            <contentResources>
soapenv:Envelope> 


応答パラメーター

返される応答には、これらのパラメーターが含まれます。

応答要素データ型説明

StatusCode

String

Webサービス呼び出しのステータスです。値の選択肢は、以下の通りです。

  • SUCCESS
  • FAILURE
ContenResourcesContentResource[]指定した成果物の依存関係のメタデータを含むオブジェクト配列です。


応答の例

サービスは、今回のSOAPの例に基づき、以下の応答を返します。

Code Block
languagexml
themeEclipse
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteAdministrationCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
      <resourceDescription>This is an analytic tab<return>
that is used to understand examine metrics split by various demographics and filters.</resourceDescription>
               <resourceId>61195</resourceId> <contentResources>
               <resourceName>Analysis<<resourceDescription/resourceName>>
               <resourceOrgId>1<<resourceId>54701</resourceOrgId>resourceId>
               <resourceName>Yellowfin Configuration <resourceType>GROUP<Database</resourceType>resourceName>
               <resourceUUID>f19e63f5-7175-4c57-897d-ed865aba8972</resourceUUID><resourceOrgId>1</resourceOrgId>
               <<resourceType>DATASOURCE</contentResources>resourceType>
            </contentResources>
            <errorCode>0</errorCode>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Web Service Request Complete</messages>
            <sessionId>92029c8ae4f1db0f33bf0b7370c1088a<<sessionId>97d7f893d787daf2806a13cdfa6f09d3</sessionId>
            <statusCode>SUCCESS</statusCode>
         </return>
      </ns2:remoteAdministrationCallResponse>
   </S:Body>
</S:Envelope>
 


手順

Javaの例を使用して、こちらの呼び出しを実行するための詳細な手順は、以下を参照してください。

Expand
title詳細手順
  • 管理ユーザーとしてのログインと、実行するwebサービスの呼び出しの指定を含む、こちらの関数の基礎的なリクエストから開始します。

    code



    Code Block
    languagejava
    themeEclipse
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    rsr.setFunction("GETEXPORTDEPENDENCIES");


  • 特定のクライアント組織を識別することもできます。


    Code Block
    languagejava
    themeEclipselanguagejava
    rsr.setLoginIdsetOrgRef("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    rsr.setFunction("GETCONTENT");

    特定のクライアント組織を識別することもできます。

     

    Code Block
    themeEclipse
    languagejava
    rsr.setOrgRef("org1"org1");


  • ContentResourceオブジェクトを使用して、依存関係を取得するコンテンツの詳細を指定します。


    Code Block
    languagejava
    themeEclipse
    ContentResource[] cr = new ContentResource[1];
      
    cr[0] = new ContentResource();
    cr[0].setResourceId(70307);
    cr[0].setResourceType("GROUP");
    cr[0].setResourceOrgId(1);


  • リクエストにオブジェクトを配置します。


    Code Block
    languagejava
    themeEclipse
    rsr.setContentResources(cr);


  • リクエストを構成したら、呼び出しを実行します。

    Code Block
    languagejava
    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    管理サービスを初期化します。実行方法の詳細は、管理webサービスを初期化します。実行方法の詳細は、こちらを参照してください。

 

返される応答には、次の要素が含まれます。:StatusCodeとContentResorce。(より詳細な情報は、上記応答パラメーターの表を参照してください)
 


  • 返される応答には、次の要素が含まれます。:StatusCodeとContentResource。(より詳細な情報は、上記応答パラメーターの表を参照してください)


完成例

以下は、こちらのwebサービスの呼び出しの完成例です。こちらを使用するには、以下の手順に従います。

  1. コードをコピーして、「ws_getcontentgetexportdependencies.jsp」として保存します。
  2. root(Yellowfin/appserver/webapps/ROOT)フォルダーにファイルを配置します。
  3. 環境に応じて、ホスト、ポート番号、管理ユーザーの詳細を調整します。
  4. インターネットブラウザから、「http://<host>:<port>/ws_getcontentgetexportdependencies.jsp」を実行します。

Code Block
languagejava
themeEclipselanguagejava
<%      
/*      ws_getcontentgetexportdependecies.jsp               */
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%@ page import="java.nio.file.Files" %>
<%@ <%
  page import="java.io.PrintWriter" %>
<%
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);       // adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
  
rsr.setLoginId("admin@yellowfin.com.au");                 // provide your Yellowfin webservices admin account
rsr.setPassword("test");         "test");                                 // changeset to be the password of the account above
rsr.setOrgId(1);
rsr.setFunction("GETCONTENTGETEXPORTDEPENDENCIES");
  
ContentResource[] cr = new ContentResource[1];
  AdministrationServiceResponse
rs = adminService.remoteAdministrationCall(rsrcr[0] = new ContentResource();
cr[0].setResourceId(70307);
cr[0].setResourceType("GROUP");
cr[0].setResourceOrgId(1);
  
rsr.setContentResources(cr);
  
AdministrationServiceResponse rs    = adminService.remoteAdministrationCall(rsr);
  
if ("SUCCESS".equals(rs.getStatusCode()) ) {
           
            out.write("<br>Success");
           
            ContentResource[] crs = rs.getContentResources();
           
            out.write("<table>");
           
            out.write("<tr><td> id </td><td> type </td><td> UUID </td></tr>");
           
            for (ContentResource c: crs) {
                       
            out.write("<tr>");            out.write("<tr>");
                        out.write("<td>" + c.getResourceId() + "</td><td>" + c.getResourceType() + "</td><td>" + c.getResourceUUID() + "</td>");
           
                        out.write("</tr>");
                    
   }
           
}
            else {
            out.write("<br>FailureFailure");
            out.write(" Code: " + rs.getErrorCode());
          
 }          
%>

 

 

...




インポートwebサービス