第2章 Decision Central のデータ移行


このリリースで提供されている Decision Central 移行ツールを使用して Red Hat JBoss BRMS 6.4 から Red Hat Decision Manager 7.1 に Decision Central データを移行して、Red Hat Decision Manager 7.1 の新しいデータ構造に対応する必要があります。さらに、お使いのアプリケーションのいずれかが、ナレッジストア REST API コール (/business-central/rest/) を介して Decision Central のスペース (以前のバージョンでは組織単位と呼ばれていました)、リポジトリー、プロジェクトと対話する場合は、Red Hat Decision Manager 7.1 でサポートされている新規エンドポイントに従い、これらの API 参照を更新する必要があります。

前提条件/事前作業

  • Red Hat JBoss BPMS 6.4 とは別のインスタンス (Red Hat JBoss EAP またはその他のインスタンス) に Red Hat Decision Manager 7.1 がインストールされている。インストールオプションは『Planning a Red Hat Process Automation Manager installation』を参照してください。
  • Red Hat JBoss BRMS 6.4 の全 Decision Central データ (該当する場合はそれに使用するデータベースも含む) の完全バックアップを作成している。これは、移行時に問題が発生した場合の予防措置です。

2.1. Decision Central 移行ツールの使用

Red Hat Decision Manager 7.1 には、修正されたデータ構造と、Red Hat JBoss BRMS 6.4 からの直接のデータ移行をサポートしないその他の機能変更が含まれています。したがって、Red Hat は、Red Hat JBoss BRMS 6.4 から Red Hat Decision Manager 7.1 にプロジェクトデータと設定を移行できる移行ツールを提供します。Decision Central ディストリビューションの .niogit ディレクトリー、または外部の Git リポジトリーで移行ツールを実行できます。移行ツールを使用して、Red Hat Decision Manager 7.1 でサポートされる新しいデータ構造と機能用に Decision Central データを準備します。

2.1.1. .niogit ディレクトリーでの移行ツールの使用

Decision Central ディストリビューションの .niogit ディレクトリーには Decision Central の全データが含まれています。.niogit ディレクトリーで Decision Central の移行ツールを使用して、Red Hat Decision Manager 7.1 への移行に向けてプロジェクトデータおよびシステム設定を準備できます。

前提条件/事前作業

  • Decision Central は Red Hat JBoss BRMS 6.4 でも Red Hat Decision Manager 7.1 でも実行されません。
  • Java 8 がインストールされていて、プロジェクトの移行ツールをインストールするパスが利用可能になっている。

手順

  1. Red Hat JBoss BPM Suite 6.4 に対する現在の Decision Central ディストリビューションにある bin/.niogit ディレクトリーの位置を特定し、新しい Red Hat Decision Manager 7.1 インストールで同じディレクトリーを見つけます。

    例:

    $ ~/$JBOSS_HOME/bin/.niogit
    $ ~/$RHDM_HOME/bin/.niogit
  2. 端末で、Red Hat JBoss BRMS 6.4 の 現在の Decision Central ディストリビューションから、新しい Red Hat Decision Manager 7.1 インストールディレクトリーの bin ディレクトリーに、.niogit ディレクトリーをコピーします。

    cp -r /$JBOSS_HOME/bin/.niogit  /$RHDM_HOME/bin/

    コピーした .niogit ディレクトリーは、移行ツールが Red Hat Decision Manager 7.1 に用意するディレクトリーで、オリジナルの .niogit ディレクトリーは Red Hat JBoss BRMS 6.4 インストールに残り、この手順で使用する移行ツールでは修正されません。

  3. Red Hat Decision Manager 7.1 の bin ディレクトリーにある .index ディレクトリーを削除します。Red Hat Decision Manager 7.1 には、Red Hat JBoss BRMS 6.4 に準拠していない特定の更新が含まれるため、このディレクトリーは削除する必要があります。bin ディレクトリーのインデックスは、移行してから Red Hat Decision Manager 7.1 を起動するときに再作成されます。
  4. Red Hat で Decision Manager 7.1 にコピーした .niogit ディレクトリーのパスを書き留めます。このパスは、移行ツールを実行する際に必要になります。
  5. プロジェクトの移行時に追加、削除、または更新する特定の dependenciesrepositories、または pluginRepositories がある場合は、これらの要素を含む pom-migration.json ファイルを作成します。移行ツールを実行すると、移行にこのファイルを含めるかどうかを尋ねるプロンプトが表示されます。

    pom-migration.json ファイルには以下のセクションが必要です。

    • "dependencies":[]
    • "repositories-add":[]
    • "repositories-remove":[]
    • "repositories-update-urls":[]
    • "pluginRepositories-add":[]
    • "pluginRepositories-remove":[]
    • "pluginRepositories-update-urls":[]

    この中の要素のいずれかがプロジェクトに適用されない場合は、解析エラーを回避するために空のセクションとして追加します。

    サンプルファイル pom-migration.json:

    {
      "dependencies":[
    
        {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"},
        {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"}
    
      ],
    
      "repositories-add":[
        {
          "id":"jboss-public-repository-group",
          "name":"JBoss Public Repository Group",
          "url":"http://repository.jboss.org/nexus/content/groups/public/",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":true,
          "snapshotUpdatePolicy":"never"
        },
        {
          "id":"kie-internal-staging-repository-group",
          "name":"KIE Internal Staging Repositories",
          "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":false,
          "snapshotUpdatePolicy":"never"
        }
      ],
    
      "repositories-remove":[
        {
          "id":"productization-repository", "url":"http://download.lab.bos.redhat.com/brewroot/repos/jb-ip-6.1-build/latest/maven/"
        }
      ],
    
      "repositories-update-urls":[
        {
          "id":"guvnor-m2-repo", "url":"http://localhost:8080/decision-central/maven3/"
        }
      ],
    
      "pluginRepositories-add":[
    
        {
          "id":"jboss-public-repository-group",
          "name":"JBoss Public Repository Group",
          "url":"http://repository.jboss.org/nexus/content/groups/public/",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":true,
          "snapshotUpdatePolicy":"never"
        },
        {
          "id":"kie-internal-staging-repository-group",
          "name":"KIE Internal Staging Repositories",
          "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":false,
          "snapshotUpdatePolicy":"never"
        }
    
      ],
      "pluginRepositories-remove":[],
      "pluginRepositories-update-urls":[]
    }

    (依存関係 のみを持つ) サンプルファイル pom-migration.json:

    {
      "dependencies":[
    
        {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"},
        {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"}
    
      ],
      "repositories-add":[],
      "repositories-remove":[],
      "repositories-update-urls":[],
      "pluginRepositories-add":[],
      "pluginRepositories-remove":[],
      "pluginRepositories-update-urls":[]
    }
  6. Red Hat カスタマーポータルの Software Downloads ページに移動し (ログインが必要)、ドロップダウンオプションから製品およびバージョンを選択します。

    • Product: Decision Manager
    • Version: 7.1
  7. Red Hat Decision Manager 7.1.0 Add-Ons をダウンロードして、ダウンロードした rhdm-7.1.0-add-ons.zip ファイルを一時ディレクトリーに展開します。
  8. 展開した rhdm-7.1.0-add-ons ディレクトリーに、rhdm-7.1-migration-tool.zip サブディレクトリーを展開します。移行ツールは bin ディレクトリーに保存されています。
  9. 端末で、rhdm-7.1-migration-tool ディレクトリーを展開した一時ディレクトリーに移動して、移行ツールを実行します。$RHDM_NIOGIT_DIR の部分は、Red Hat Process Automation Manager 7.1 インストールにコピーしておいた .niogit ディレクトリーのパスになります。

    Linux または UNIX ベースのシステムの場合:

    $ cd $INSTALL_DIR/rhdm-7.1-migration-tool/bin
    $ ./migration-tool.sh -t $RHDM_NIOGIT_DIR

    Windows の場合:

    $ cd $INSTALL_DIR\rhdm-7.1-migration-tool\bin
    $ migration-tool.bat -t $RHDM_NIOGIT_DIR

    コマンドプロンプトが表示されると、以下のオプションが表示されます。

    • Project structure migration: Red Hat JBoss BRMS 6.4 プロジェクトリポジトリー構造を、Red Hat Decision Manager 7.1 で使用される新しいプロジェクト指向の構造に移行します。
    • System configuration directory structure migration: Red Hat JBoss BRMS 6.4 で使用される system.git リポジトリー構造を、Red Hat Decision Manager 7.1 で使用される新しい構造に移行します。この移行オプションでは、プロジェクト構造の移行を最初に実行する必要があります。
    • Forms migration: Red Hat Decision Manager 7.1 で必要な依存関係を持つ pom.xml ファイルを更新します。この移行オプションでは、プロジェクト構造の移行とシステム設定ディレクトリー構造の移行を最初に実行する必要があります。
    • All: すべての移行オプションを順番に実行します。
    • Exit: 移行ツールを終了します。
  10. All オプションを選択して、移行を順番に実行します。

    注記

    移行オプションを一度に 1 つずつ実行する場合は、最初に実行する移行オプションを実行します。ツールを実行したら、Decision Central 移行ツールを再度実行して、次に実行する移行オプションを選択します。

  11. 特定の移行オプションを実行するようにプロンプトが表示されるたびに yes を入力します。

    POM 移行オプションで、作成しておいた外部の pom-migration.json ファイルのパスを指定する場合は、プロンプトが表示された時に yes を入力して、パスを入力します。

  12. ツールの実行が終了したら、Exit オプションを選択して移行ツールを終了します。

    .niogit ディレクトリー構造は、Red Hat Decision Manager 7.1 の Decision Central と互換性があります。プロジェクトディレクトリーは別のリポジトリーにあり、その他の関連する設定はすべて移行されています。新しい .niogit ディレクトリーに移動して、再構築したコンテンツを確認できます。

2.1.2. 外部 Git リポジトリーでの移行ツールの使用

.niogit ディレクトリー外にある Git リポジトリーに Decision Central プロジェクトデータを保存する場合は、外部リポジトリーで Decision Central 移行ツールを使用して、Red Hat Decision Manager 7.1 のプロジェクトデータを準備することもできます。Git リポジトリーのプロジェクトディレクトリー内のファイルだけが移行ツールにより再構築されます。

前提条件/事前作業

Java 8 がインストールされていて、プロジェクトの移行ツールをインストールするパスが利用可能になっている。

手順

  1. (リポジトリーのクローンが作成されていない場合は) ローカルディレクトリーで、移行するプロジェクトを含む Git リポジトリーのクローンを作成します。

    $ cd $REPO_DIR/
    $ git clone $GIT_REPO_URL
  2. クローンを作成した Git リポジトリーのパスを書き留めます。移行ツールを実行する際にパスが必要になります。
  3. 移行ツールの実行後に、新たに移行したリポジトリーのコピーを置く出力ディレクトリーを作成します。既存のディレクトリーを出力場所としても使用できます。この出力ディレクトリーのパスを書き留めます。移行ツールは、クローンとして作成したリポジトリーのコピー上で作動します。ツールの実行時に新しい出力ディレクトリーのパスを求めるプロンプトがこのツールにより表示されます。
  4. プロジェクトの移行時に追加、削除、または更新する特定の dependenciesrepositories、または pluginRepositories がある場合は、これらの要素を含む pom-migration.json ファイルを作成します。移行ツールを実行すると、移行にこのファイルを含めるかどうかを尋ねるプロンプトが表示されます。

    pom-migration.json ファイルには以下のセクションが必要です。

    • "dependencies":[]
    • "repositories-add":[]
    • "repositories-remove":[]
    • "repositories-update-urls":[]
    • "pluginRepositories-add":[]
    • "pluginRepositories-remove":[]
    • "pluginRepositories-update-urls":[]

    この中の要素のいずれかがプロジェクトに適用されない場合は、解析エラーを回避するために空のセクションとして追加します。

    サンプルファイル pom-migration.json:

    {
      "dependencies":[
    
        {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"},
        {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"}
    
      ],
    
      "repositories-add":[
        {
          "id":"jboss-public-repository-group",
          "name":"JBoss Public Repository Group",
          "url":"http://repository.jboss.org/nexus/content/groups/public/",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":true,
          "snapshotUpdatePolicy":"never"
        },
        {
          "id":"kie-internal-staging-repository-group",
          "name":"KIE Internal Staging Repositories",
          "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":false,
          "snapshotUpdatePolicy":"never"
        }
      ],
    
      "repositories-remove":[
        {
          "id":"productization-repository", "url":"http://download.lab.bos.redhat.com/brewroot/repos/jb-ip-6.1-build/latest/maven/"
        }
      ],
    
      "repositories-update-urls":[
        {
          "id":"guvnor-m2-repo", "url":"http://localhost:8080/decision-central/maven3/"
        }
      ],
    
      "pluginRepositories-add":[
    
        {
          "id":"jboss-public-repository-group",
          "name":"JBoss Public Repository Group",
          "url":"http://repository.jboss.org/nexus/content/groups/public/",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":true,
          "snapshotUpdatePolicy":"never"
        },
        {
          "id":"kie-internal-staging-repository-group",
          "name":"KIE Internal Staging Repositories",
          "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group",
          "releasesEnabled":true,
          "releasesUpdatePolicy":"never",
          "snapshotEnabled":false,
          "snapshotUpdatePolicy":"never"
        }
    
      ],
      "pluginRepositories-remove":[],
      "pluginRepositories-update-urls":[]
    }

    (依存関係 のみを持つ) サンプルファイル pom-migration.json:

    {
      "dependencies":[
    
        {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"},
        {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"}
    
      ],
      "repositories-add":[],
      "repositories-remove":[],
      "repositories-update-urls":[],
      "pluginRepositories-add":[],
      "pluginRepositories-remove":[],
      "pluginRepositories-update-urls":[]
    }
  5. Red Hat カスタマーポータルの Software Downloads ページに移動し (ログインが必要)、ドロップダウンオプションから製品およびバージョンを選択します。

    • Product: Decision Manager
    • Version: 7.1
  6. Red Hat Decision Manager 7.1.0 Add-Ons をダウンロードして、ダウンロードした rhdm-7.1.0-add-ons.zip ファイルを一時ディレクトリーに展開します。
  7. 展開した rhdm-7.1.0-add-ons ディレクトリーに、rhdm-7.1-migration-tool.zip サブディレクトリーを展開します。移行ツールは bin ディレクトリーに保存されています。
  8. コマンド端末で、rhdm-7.1-migration-tool ディレクトリーを展開した一時ディレクトリーに移動して、移行ツールを実行します。$GIT_REPO_PATH の部分は、作成した Git リポジトリーのパスになります。

    Linux または UNIX ベースのシステムの場合:

    $ cd $INSTALL_DIR/rhdm-7.1-migration-tool/bin
    $ ./migration-tool.sh -t $GIT_REPO_PATH

    Windows の場合:

    $ cd $INSTALL_DIR\rhdm-7.1-migration-tool\bin
    $ migration-tool.bat -t $GIT_REPO_PATH
  9. 表示されるコマンドプロンプトに、移行したリポジトリーのコピーを置く出力ディレクトリーへのパスを入力します。移行ツールは、クローンとして作成したリポジトリーのコピー上で作動し、指定した出力先に新しいリポジトリーを配置します。

    出力先を入力後、移行ツールがリポジトリーのコピーを用意し、すべてのプロジェクトディレクトリーが Red Hat Decision Manager 7.1 と互換性を保てるように再構築します。

    コマンドプロンプトに、以下の追加移行オプションが表示されます。

    • POMs migration: Red Hat Decision Manager 7.1 で必要な依存関係が含まれる pom.xml を更新します。
    • All: 残りのすべての移行オプションを順番に実行します。
    • Exit: 移行ツールを終了します。
    注記

    出力先で移行ツールを開始するとこのオプションが自動的に実行するため、Project structure migration オプションは表示されません。

  10. All オプションを選択して、移行を順番に実行します。

    注記

    移行オプションを一度に 1 つずつ実行する場合は、最初に実行する移行オプションを実行します。ツールを実行したら、Decision Central 移行ツールを再度実行して、次に実行する移行オプションを選択します。

  11. 特定の移行オプションを実行するようにプロンプトが表示されるたびに yes を入力します。

    POM 移行オプションで、作成しておいた外部の pom-migration.json ファイルのパスを指定する場合は、プロンプトが表示された時に yes を入力して、パスを入力します。

  12. ツールの実行が終了したら、Exit オプションを選択して移行ツールを終了します。

    指定した出力先のプロジェクトディレクトリーは、Red Hat Decision Manager 7.1 の Decision Central と互換性のある個々のリポジトリーに分かれます。新しいプロジェクトリポジトリーは、作業ディレクトリーのないベアリポジトリーであるため、コンテンツファイルを表示しません。各リポジトリーのクローンを作成してベアリポジトリーではないリポジトリーを作成し、ディレクトリーのコンテンツを確認します。

  13. Red Hat Decision Manager 7.1 の Decision Central にログインします。
  14. 各プロジェクトに対して、プロジェクトのスペースを作成または選択し、Import Project をクリックします。
  15. 新たに構築したプロジェクトリポジトリーの リポジトリー URL を入力します。この URL は、出力先へのローカルファイルパス (移行ツールを実行したワークステーションから直接インポートしている場合)、GitHub URL、またはリポジトリーをアップロードしたその他のファイルのホスト先にできます。

    例: ローカルファイルの場所

    file:///$OUTPUT_DIR/loan-application.git

    例: GitHub リポジトリーの場所

    https://github.com/$REPO/loan-application.git
    注記

    プロジェクトデータで Git hooks を使用する場合は、移行を調整する hooks スクリプトの更新が必要になる場合があります。

2.2. Decision Central ナレッジストアへの API 参照の更新

ナレッジストア REST API は Red Hat Decision Manager 7.1 では非推奨になっていますが、特定のエンドポイントは依然としてサポートされているため、Decision Central リソースを管理し続けることができます。アプリケーションのいずれかが、ナレッジストア REST API コール (/decision-central/rest/) を介して Decision Central スペース (以前は組織単位と呼ばれていました)、リポジトリー、プロジェクトと対話する場合は、Red Hat Decision Manager 7.1 でサポートされる新しいエンドポイントに従って、これらの API 参照を更新する必要があります。

手順

必要に応じて、アプリケーションコードで、http://<SERVER>:<PORT>/decision-central/rest/<ENDPOINT> 形式の Decision Central ナレッジストアへの古い REST API コールを、「サポートされるナレッジストア REST API エンドポイント」 で対応する新しいナレッジストア REST API コールに置き換えます。

Red Hat Decision Manager 7.1 でコンテンツを再構築した結果、古い Decision Central REST API コールと、Red Hat Decision Manager 7.1 で対応する REST API コールとの間で、エンドポイントが変わる可能性があります。新しいエンドポイントを使用して古い Decision Central REST API コールを置き換えるようにしてください。古いコールを置き換えるための、対応する REST API コールが一覧の中から見つからない場合は、コールが Red Hat Decision Manager 7.1 でサポートされなくなったことを示しています。

以下の例は、スペースに対する、ナレッジストア REST API コールへの更新です。

古いナレッジストア REST API コール:

http://localhost:8080/decision-central/rest/organizational-units

新しいナレッジストア REST API コール:

http://localhost:8080/decision-central/rest/spaces

2.2.1. サポートされるナレッジストア REST API エンドポイント

ナレッジストア REST API は、Red Hat Decision Manager 内のスペースおよびプロジェクトを管理し、以前の内 REST API リクエストまたは jobs についての情報を取得するエンドポイントを提供します。

2.2.1.1. スペース

ナレッジストア REST API は Decision Central のスペースを管理するための以下のエンドポイントをサポートします。ナレッジストア REST API のベース URL は http://SERVER:PORT/decision-central/rest/ です。ユーザーロール rest-all では、すべてのリクエストで HTTP 基本認証またはトークンベースの認証が必要です。

[GET] /spaces

Decision Central のすべてのスペースを返します。

サーバーの応答例 (JSON)

[
  {
    "name": "MySpace",
    "description": null,
    "projects": [
      {
        "name": "Employee_Rostering",
        "spaceName": "MySpace",
        "groupId": "employeerostering",
        "version": "1.0.0-SNAPSHOT",
        "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
        "publicURIs": [
          {
            "protocol": "git",
            "uri": "git://localhost:9418/MySpace/example-Employee_Rostering"
          },
          {
            "protocol": "ssh",
            "uri": "ssh://localhost:8001/MySpace/example-Employee_Rostering"
          }
        ]
      },
      {
        "name": "Mortgage_Process",
        "spaceName": "MySpace",
        "groupId": "mortgage-process",
        "version": "1.0.0-SNAPSHOT",
        "description": "Getting started loan approval process in BPMN2, decision table, business rules, and forms.",
        "publicURIs": [
          {
            "protocol": "git",
            "uri": "git://localhost:9418/MySpace/example-Mortgage_Process"
          },
          {
            "protocol": "ssh",
            "uri": "ssh://localhost:8001/MySpace/example-Mortgage_Process"
          }
        ]
      }
    ],
    "owner": "admin",
    "defaultGroupId": "com.myspace"
  },
  {
    "name": "MySpace2",
    "description": null,
    "projects": [
      {
        "name": "IT_Orders",
        "spaceName": "MySpace",
        "groupId": "itorders",
        "version": "1.0.0-SNAPSHOT",
        "description": "Case Management IT Orders project",
        "publicURIs": [
          {
            "protocol": "git",
            "uri": "git://localhost:9418/MySpace/example-IT_Orders-1"
          },
          {
            "protocol": "ssh",
            "uri": "ssh://localhost:8001/MySpace/example-IT_Orders-1"
          }
        ]
      }
    ],
    "owner": "admin",
    "defaultGroupId": "com.myspace"
  }
]

[GET] /spaces/{spaceName}

指定したスペースに関する情報を返します。

Expand
表2.1 リクエストパラメーター
名前説明タイプ要件

spaceName

取得するスペースの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "name": "MySpace",
  "description": null,
  "projects": [
    {
      "name": "Mortgage_Process",
      "spaceName": "MySpace",
      "groupId": "mortgage-process",
      "version": "1.0.0-SNAPSHOT",
      "description": "Getting started loan approval process in BPMN2, decision table, business rules, and forms.",
      "publicURIs": [
        {
          "protocol": "git",
          "uri": "git://localhost:9418/MySpace/example-Mortgage_Process"
        },
        {
          "protocol": "ssh",
          "uri": "ssh://localhost:8001/MySpace/example-Mortgage_Process"
        }
      ]
    },
    {
      "name": "Employee_Rostering",
      "spaceName": "MySpace",
      "groupId": "employeerostering",
      "version": "1.0.0-SNAPSHOT",
      "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
      "publicURIs": [
        {
          "protocol": "git",
          "uri": "git://localhost:9418/MySpace/example-Employee_Rostering"
        },
        {
          "protocol": "ssh",
          "uri": "ssh://localhost:8001/MySpace/example-Employee_Rostering"
        }
      ]
    },
    {
      "name": "Evaluation_Process",
      "spaceName": "MySpace",
      "groupId": "evaluation",
      "version": "1.0.0-SNAPSHOT",
      "description": "Getting started Business Process for evaluating employees",
      "publicURIs": [
        {
          "protocol": "git",
          "uri": "git://localhost:9418/MySpace/example-Evaluation_Process"
        },
        {
          "protocol": "ssh",
          "uri": "ssh://localhost:8001/MySpace/example-Evaluation_Process"
        }
      ]
    },
    {
      "name": "IT_Orders",
      "spaceName": "MySpace",
      "groupId": "itorders",
      "version": "1.0.0-SNAPSHOT",
      "description": "Case Management IT Orders project",
      "publicURIs": [
        {
          "protocol": "git",
          "uri": "git://localhost:9418/MySpace/example-IT_Orders"
        },
        {
          "protocol": "ssh",
          "uri": "ssh://localhost:8001/MySpace/example-IT_Orders"
        }
      ]
    }
  ],
  "owner": "admin",
  "defaultGroupId": "com.myspace"
}

[POST] /spaces

Decision Central でスペースを作成します。

Expand
表2.2 リクエストパラメーター
名前説明タイプ要件

body

新規スペースの namedescriptionownerdefaultGroupId、およびその他のコンポーネント。

要求の本文

必須

リクエストボディ (JSON) 例

{
  "name": "NewSpace",
  "description": "My new space.",
  "owner": "admin",
  "defaultGroupId": "com.newspace"
}

サーバーの応答例 (JSON)

{
  "jobId": "1541016978154-3",
  "status": "APPROVED",
  "spaceName": "NewSpace",
  "owner": "admin",
  "defaultGroupId": "com.newspace",
  "description": "My new space."
}

[DELETE] /spaces/{spaceName}

Decision Central からスペースを削除します。

Expand
表2.3 リクエストパラメーター
名前説明タイプ要件

spaceName

削除するスペースの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541127032997-8",
  "status": "APPROVED",
  "spaceName": "MySpace",
  "owner": "admin",
  "description": "My deleted space.",
  "repositories": null
}

2.2.1.2. プロジェクト

ナレッジストア REST API は Decision Central のプロジェクトを管理、ビルド、デプロイメントするための以下のエンドポイントをサポートします。ナレッジストア REST API のベース URL は http://SERVER:PORT/decision-central/rest/ です。ユーザーロール rest-all では、すべてのリクエストで HTTP 基本認証またはトークンベースの認証が必要です。

[GET] /spaces/{spaceName}/projects

指定したスペースにあるプロジェクトを返します。

Expand
表2.4 リクエストパラメーター
名前説明タイプ要件

spaceName

取得するプロジェクトのスペース名

文字列

必須

サーバーの応答例 (JSON)

[
  {
    "name": "Mortgage_Process",
    "spaceName": "MySpace",
    "groupId": "mortgage-process",
    "version": "1.0.0-SNAPSHOT",
    "description": "Getting started loan approval process in BPMN2, decision table, business rules, and forms.",
    "publicURIs": [
      {
        "protocol": "git",
        "uri": "git://localhost:9418/MySpace/example-Mortgage_Process"
      },
      {
        "protocol": "ssh",
        "uri": "ssh://localhost:8001/MySpace/example-Mortgage_Process"
      }
    ]
  },
  {
    "name": "Employee_Rostering",
    "spaceName": "MySpace",
    "groupId": "employeerostering",
    "version": "1.0.0-SNAPSHOT",
    "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
    "publicURIs": [
      {
        "protocol": "git",
        "uri": "git://localhost:9418/MySpace/example-Employee_Rostering"
      },
      {
        "protocol": "ssh",
        "uri": "ssh://localhost:8001/MySpace/example-Employee_Rostering"
      }
    ]
  },
  {
    "name": "Evaluation_Process",
    "spaceName": "MySpace",
    "groupId": "evaluation",
    "version": "1.0.0-SNAPSHOT",
    "description": "Getting started Business Process for evaluating employees",
    "publicURIs": [
      {
        "protocol": "git",
        "uri": "git://localhost:9418/MySpace/example-Evaluation_Process"
      },
      {
        "protocol": "ssh",
        "uri": "ssh://localhost:8001/MySpace/example-Evaluation_Process"
      }
    ]
  },
  {
    "name": "IT_Orders",
    "spaceName": "MySpace",
    "groupId": "itorders",
    "version": "1.0.0-SNAPSHOT",
    "description": "Case Management IT Orders project",
    "publicURIs": [
      {
        "protocol": "git",
        "uri": "git://localhost:9418/MySpace/example-IT_Orders"
      },
      {
        "protocol": "ssh",
        "uri": "ssh://localhost:8001/MySpace/example-IT_Orders"
      }
    ]
  }
]

[GET] /spaces/{spaceName}/projects/{projectName}

指定したスペースにある指定したプロジェクト関する情報を返します。

Expand
表2.5 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

取得するプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "name": "Employee_Rostering",
  "spaceName": "MySpace",
  "groupId": "employeerostering",
  "version": "1.0.0-SNAPSHOT",
  "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
  "publicURIs": [
    {
      "protocol": "git",
      "uri": "git://localhost:9418/MySpace/example-Employee_Rostering"
    },
    {
      "protocol": "ssh",
      "uri": "ssh://localhost:8001/MySpace/example-Employee_Rostering"
    }
  ]
}

[POST] /spaces/{spaceName}/projects

指定したスペースにプロジェクトを作成します。

Expand
表2.6 リクエストパラメーター
名前説明タイプ要件

spaceName

新規プロジェクトが作成されるスペース名

文字列

必須

body

新規プロジェクトの namegroupIdversiondescription、およびその他のコンポーネント。

要求の本文

必須

リクエストボディ (JSON) 例

{
  "name": "Employee_Rostering",
  "groupId": "employeerostering",
  "version": "1.0.0-SNAPSHOT",
  "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill."
}

サーバーの応答例 (JSON)

{
  "jobId": "1541017411591-6",
  "status": "APPROVED",
  "spaceName": "MySpace",
  "projectName": "Employee_Rostering",
  "projectGroupId": "employeerostering",
  "projectVersion": "1.0.0-SNAPSHOT",
  "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill."
}

[DELETE] /spaces/{spaceName}/projects/{projectName}

指定したスペースから指定したプロジェクトを削除します。

Expand
表2.7 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

削除するプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541128617727-10",
  "status": "APPROVED",
  "projectName": "Employee_Rostering",
  "spaceName": "MySpace"
}

[POST] /spaces/{spaceName}/git/clone

指定した Git アドレスから指定したスペースにプロジェクトのクローンを作成します。

Expand
表2.8 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのクローンを作成するスペース名

文字列

必須

body

クローンするプロジェクトの namedescription、Git リポジトリーの userNamepassword、および gitURL

要求の本文

必須

リクエストボディ (JSON) 例

{
  "name": "Employee_Rostering",
  "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
  "userName": "baAdmin",
  "password": "password@1",
  "gitURL": "git://localhost:9418/MySpace/example-Employee_Rostering"
}

サーバーの応答例 (JSON)

{
  "jobId": "1541129488547-13",
  "status": "APPROVED",
  "cloneProjectRequest": {
    "name": "Employee_Rostering",
    "description": "Employee rostering problem optimisation using Planner. Assigns employees to shifts based on their skill.",
    "userName": "baAdmin",
    "password": "password@1",
    "gitURL": "git://localhost:9418/MySpace/example-Employee_Rostering"
  },
  "spaceName": "MySpace2"
}

[POST] /spaces/{spaceName}/projects/{projectName}/maven/compile

指定したスペースで指定したプロジェクトをコンパイルします (mvn compile と同等)。

Expand
表2.9 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

コンパイルするプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541128617727-10",
  "status": "APPROVED",
  "projectName": "Employee_Rostering",
  "spaceName": "MySpace"
}

[POST] /spaces/{spaceName}/projects/{projectName}/maven/test

指定したスペースで指定したプロジェクトをテストします (mvn test と同等)。

Expand
表2.10 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

テストするプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541132591595-19",
  "status": "APPROVED",
  "projectName": "Employee_Rostering",
  "spaceName": "MySpace"
}

[POST] /spaces/{spaceName}/projects/{projectName}/maven/install

指定したスペースで指定したプロジェクトをインストールします (mvn install と同等)。

Expand
表2.11 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

インストールするプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541132668987-20",
  "status": "APPROVED",
  "projectName": "Employee_Rostering",
  "spaceName": "MySpace"
}

[POST] /spaces/{spaceName}/projects/{projectName}/maven/deploy

指定したスペースで指定したプロジェクトをデプロイします (mvn deploy と同等)。

Expand
表2.12 リクエストパラメーター
名前説明タイプ要件

spaceName

プロジェクトのあるスペースの名前

文字列

必須

projectName

デプロイするプロジェクトの名前

文字列

必須

サーバーの応答例 (JSON)

{
  "jobId": "1541132816435-21",
  "status": "APPROVED",
  "projectName": "Employee_Rostering",
  "spaceName": "MySpace"
}

2.2.1.3. ジョブ (API リクエスト)

ナレッジストア REST API の POSTDELETE リクエストはすべて、返されるリクエスト詳細のほかに、各リクエストに関連付けられたジョブ ID を返します。ジョブ ID を使用すると、リクエストステータスを確認したり、送信されたリクエストを削除することができます。

ナレッジストア REST API リクエストもしくは ジョブ には、以下のステータスがあります。

Expand
表2.13 ジョブステータス (API リクエストステータス)
ステータス説明

ACCEPTED

リクエストが受け入れられ、処理中である。

BAD_REQUEST

リクエストに無効なコンテンツが含まれ、受け入れられなかった。

RESOURCE_NOT_EXIST

要求されたリソース (パス) が存在しない。

DUPLICATE_RESOURCE

リソースがすでに存在する。

SERVER_ERROR

Decision Server でエラーが発生した。

SUCCESS

リクエストが正常に完了した。

FAIL

リクエストが失敗した。

APPROVED

リクエストが承認された。

DENIED

リクエストが拒否された。

GONE

以下のいずれかの理由でリクエストのジョブ ID が見つからなかった。

  • リクエストが明示的に削除された。
  • リクエストが完了してステータスキャッシュから削除されている。キャッシュが最大容量に達すると、リクエストはステータスキャッシュから削除されます。
  • リクエストが元々存在しなかった。

ナレッジストア REST API は、送信済み API リクエストの取得または削除用の以下のエンドポイントをサポートします。ナレッジストア REST API のベース URL は http://SERVER:PORT/decision-central/rest/ です。ユーザーロール rest-all では、すべてのリクエストで HTTP 基本認証またはトークンベースの認証が必要です。

[GET] /jobs/{jobId}

指定されたジョブのステータスを返します (以前に送信された API リクエスト)。

Expand
表2.14 リクエストパラメーター
名前説明タイプ要件

jobId

取得するジョブの ID (例: 1541010216919-1)

文字列

必須

サーバーの応答例 (JSON)

{
  "status": "SUCCESS",
  "jobId": "1541010216919-1",
  "result": null,
  "lastModified": 1541010218352,
  "detailedResult": [
    "level:INFO, path:null, text:Build of module 'Mortgage_Process' (requested by system) completed.\n Build: SUCCESSFUL"
  ]
}

[DELETE] /jobs/{jobId}

指定したジョブ (以前に送信された API リクエスト) を削除します。ジョブがまだ処理されていない場合は、このリクエストはジョブをジョブキューから削除します。実行中のジョブがキャンセルされたり停止されたりすることはありません。

Expand
表2.15 リクエストパラメーター
名前説明タイプ要件

jobId

削除するジョブの ID (例: 1541010216919-1)

文字列

必須

サーバーの応答例 (JSON)

{
  "status": "GONE",
  "jobId": "1541010216919-1",
  "result": null,
  "lastModified": 1541132054916,
  "detailedResult": [
    "level:INFO, path:null, text:Build of module 'Mortgage_Process' (requested by system) completed.\n Build: SUCCESSFUL"
  ]
}

2.3. Decision Central での移行の確認

Decision Central のデータをすべて移行した後に、Red Hat Decision Manager 7.1 の新しい Decision Central で移行が成功していることを確認します。

前提条件/事前作業

Decision Central 移行ツールを使用して、Red Hat JBoss BRMS 6.4 からプロジェクトデータを移行している。

手順

  1. お使いのインストールに応じて、Red Hat Decision Manager 7.1 を起動します。

    例: Red Hat JBoss EAP を使用したインストール

    $ ~/$EAP_HOME/bin/standalone.sh -c standalone-full.xml
  2. お使いの認証情報を使用して Decision Central にログインして、Menu Design Projects に移動します。
  3. すべてのプロジェクトが移行しているのを確認し、各プロジェクトを選択して、移行したプロジェクトアセットを確認します。
  4. 各プロジェクトに対して、プロジェクトウィンドウの右上にある Build をクリックしてから Deploy をクリックし、移行したプロジェクトデータおよび設定した Decision Server を検証します。

2.3.1. Decision Central 移行問題のトラブルシューティング

Red Hat Decision Manager 7.1 への Decision Central の移行で問題が発生したら、以下の点を推奨のトラブルシューティングの内容を確認してください。

  • プロジェクトデータが Decision Central にない場合は、Red Hat Decision Manager 7.1 の.niogit ディレクトリーに再構築したデータが含まれており、Red Hat Decision Manager 7.1 の正しいインストール場所 (例: ~/$EAP_HOME/bin/) にあることを確認します。
  • プロジェクトがビルドできない場合はプロジェクトファイル pom.xml を開き、http://<SERVER>:<PORT>/decision-central/maven2/ リポジトリーが存在する場合は削除します。このリポジトリーが存在すると、Red Hat Decision Manager 7.1 でプロジェクトが適切にビルドできません。このリポジトリーに保存するプロジェクトデータが含まれている場合は、データ用の新しいリポジトリーを作成し、そのリポジトリーを pom.xml ファイルの依存関係として追加します。

    削除する pom.xml ファイルの例:

    <repository>
      <id>guvnor-m2-repo</id>
      <name>Guvnor M2 Repo</name>
      <url>http://localhost:8080/decision-central/maven2/</url>
    </repository>
  • Decision Server にプロジェクトをデプロイできない場合は、Decision Server インストールおよび設定を確認します。詳細は『Planning a Red Hat Process Automation Manager installation』を参照してください。
  • 移行問題を解決できない場合は、新しい Red Hat Decision Manager 7.1 インストールで移行プロセスを再実行してください。
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

Red Hat ドキュメントについて

Legal Notice

Theme

© 2026 Red Hat
トップに戻る