---
schema_version: "1"
id: 847f4981b0053bbeb012f58d44de133cc6eef0635e61ca43f00fcbc9edef01c1
title: Quartz Connector
collection: mulesoft
version: current
locale: ja-jp
portal_url: https://docs.salesforce.com/mulesoft/current/ja-jp/quartz-connector/latest/index.md
canonical_url: https://docs.mulesoft.com/jp/quartz-connector/latest/
source_site: docs.mulesoft.com
content_type: documentation
content_hash: c3dca7cec2a4955732ce4870024fdcf2d4e71ef1e9164075eb228e958cc9b304
description: MuleSoft Documentation Site
release: 0.3.9
latest: true
---
# Quartz Connector

Quartz Connector は非推奨です。タスクをスケジュールする場合、代わりに ​[Poll スコープ](#3.9@mule-runtime::poll-reference.adoc)​を使用することをお勧めします。

Quartz Connector では、Mule フロー内外のプログラムによるイベントのスケジュールをサポートしています。Quartz エンドポイントを使用して、スケジュールされれた時間に実行するために外部入力の受信を必要としないフローをトリガーできます。

たとえば、インバウンド Quartz エンドポイントは定期的な間隔でのリモート場所からの温度レポートなどのインバウンドイベントをトリガーできます。

アウトバウンド Quartz エンドポイントは本来ならばすぐに実行されるイベントを遅延できます。たとえば、Mule フローでの処理が完了した直後に送信メールが送信されるのを防止できます。代わりに、Quartz を使用して次の正時まで遅延できます。

**ポーリング**​

フローの先頭で Poll スコープを使用するオプションもあります。この場合も、Cron 式とウォーターマークがサポートされます。詳細は、​[「Poll スコープ」](#3.9@mule-runtime::poll-reference.adoc)​を参照してください。

複数のワーカーとノードがある環境で実行した場合、Quartz スケジューラーはデフォルトで Poll スコープが単一のノードのみで実行するのに十分なほど「スマート」な各ノードで実行されます。Quartz スケジューラーは Poll スコープと同じ動作をするように設定できますが、JDBC JobStore の設定が必要になります。

## [](#このコネクタのインストール方法)このコネクタのインストール方法

1. Anypoint Studio で、Studio タスクバーの Exchange アイコンをクリックします。
2. Anypoint Exchange で \[Login (ログイン)\] をクリックします。
3. コネクタを検索して \[Install (インストール)\] をクリックします。
4. 画面の指示に従ってコネクタをインストールします。

Studio の更新がある場合、右下隅にメッセージが表示されます。メッセージをクリックすると、更新をインストールできます。

## [](#configuration-設定)Configuration (設定)

Quartz エンドポイントの設定は 2 つのフェーズで構成されます。

1. Mule フロー内で Quartz エンドポイントを配置する場所を決定し、パレットから Mule フローを構成するプロセッサーのシーケンスの適切な場所までドラッグします。  
    
    1. フローの先頭に Quartz エンドポイントを配置した場合、インバウンドエンドポイント (メッセージソースなど) として動作し、インバウンドイベントのタイミングを制御します。
    2. Quartz プロセッサーをフローの中盤または最後に配置した場合、アウトバウンドエンドポイントとして動作し、アウトバウンドイベントが起こるタイミングを制御します。
2. プロパティエディターのさまざまなタブの項目の値を指定して Quartz エンドポイントを設定します。プロパティエディターは、\[Message Flow (メッセージフロー)\] キャンバスで Quartz アイコンをクリックして開きます。

### [](#general-一般-タブ)\[General (一般)\] タブ

![quartz connector 02154](/mulesoft/current/ja-jp/quartz-connector/latest/_images/quartz-connector-02154.png)

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 50%;">
<col style="width: 50%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">項目</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Display Name (表示名)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">デフォルトは汎用エンドポイント名 (この場合は Quartz) です。​<code>Mail Delivery Scheduler</code>​ のように、エンドポイントの特定のロールを反映するように表示名 (使用できるのは英数字のみ) を変更します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Stateful (ステートフル)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ジョブが永続的であるかどうかを決定します。永続的な場合、各要求でジョブの詳細要求が保持されます。さらに重要なことに、トリガーされた各ジョブは連続的に実行されます。ジョブの実行時間が次のトリガーを超えた場合、ジョブは現在のジョブの実行を待機します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Job Name (ジョブ名)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Hourly Mail Dispatcher</code>​ など、このエンドポイントで実行されるジョブ (イベントなど) を識別するのに役立つ内部名を指定します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Cron Expression (Cron 式)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">イベントをスケジュールするための ​<strong>cron</strong>​ 式を指定します。これは「ジョブ」とも呼ばれます。​<strong>cron</strong>​ 構文の概要については、 <a href="http://en.wikipedia.org/wiki/Cron">Wikipedia の Cron の項目</a>​を参照してください。このプロパティは、反復間隔プロパティを指定していない場合に必要です。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Cron Time Zone (Cron のタイムゾーン)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="https://docs.oracle.com/javase/7/docs/api/java/util/TimeZone.html">java 形式</a>​でタイムゾーンを指定します。 ここで、またはシステムプロパティとして値を指定しなかった場合、マシンのオペレーティングシステムで設定されているタイムゾーンが使用されます。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Repeat Interval (反復間隔)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ジョブ間の時間を指定します。このプロパティは、Cron 式を指定していない場合に必要です。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Repeat Count (反復数)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ジョブを繰り返す回数を指定します。-1 に設定した場合、ジョブは無限に繰り返されます。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Start Delay (開始遅延)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">最初のジョブがトリガーされる前に経過する時間 (ミリ秒) を指定します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Job (ジョブ)</strong></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p>ジョブを実行する関連付けられた要素を追加します。次の使用可能なオプションがあります。</p>
</div>
<div class="ulist">
<ul>
<li>
<p>quartz:custom-job</p>
</li>
<li>
<p>quartz:event-generator-job</p>
</li>
<li>
<p>quartz:endpoint-polling-job</p>
</li>
<li>
<p>quartz:scheduled-dispatch-job</p>
</li>
</ul>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Connector Configuration (コネクタ設定)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ドロップダウンリストを使用して、このエンドポイント用に以前に設定されたコネクタ設定を選択します。このエンドポイントの種別用のコネクタ設定を作成していない場合、このウィンドウから ​<strong>[Add (追加)]</strong>​ をクリックして作成できます。 以前に作成したグローバル要素を変更するには、​<strong>[Edit (編集)]</strong>​ をクリックします。</p></td>
</tr>
</tbody>
</table>

### [](#advanced-詳細-タブ)\[Advanced (詳細)\] タブ

![quartz connector 26774](/mulesoft/current/ja-jp/quartz-connector/latest/_images/quartz-connector-26774.png)

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 50%;">
<col style="width: 50%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">項目</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Address (住所)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code><a href="http://localhost:8081/file" class="bare">http://localhost:8081/file</a></code>​ など、このエンドポイントのアドレスを入力します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Response Timeout (応答タイムアウト)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">エンドポイントが応答を待機する必要がある時間 (ミリ秒) を指定します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Encoding (エンコード)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ドロップダウンリストから、メッセージデータに使用する文字セット。(UTF-8 など)。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Disable Transport Transformer (トランスポートトランスフォーマーを無効化)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">エンドポイントのデフォルトの応答トランスポートを​<em>使用しない</em>​場合、このボックスをオンにします。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>MIME Type (MIME タイプ)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ドロップダウンリストからこのエンドポイントでサポートする形式のいずれかを選択します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Connector Endpoint (コネクタエンドポイント)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">ドロップダウンリストを使用して、以前に設定されたグローバルエンドポイントテンプレートを選択します (存在する場合)。このエンドポイントの種別用のグローバル要素を作成していない場合、​<strong>[Add (追加)]</strong>​ をクリックして、表示されるペインの項目に入力します。以前に作成したグローバル要素を変更するには、​<strong>[Edit (編集)]</strong>​ をクリックします。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Enable default events tracking (デフォルトイベント追跡を有効化)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">このエンドポイントのデフォルト​<a href="#3.9@mule-runtime::business-events.adoc" class="xref unresolved">ビジネスイベント</a>​追跡を有効にします。</p></td>
</tr>
</tbody>
</table>

### [](#transformers-トランスフォーマー-タブ)\[Transformers (トランスフォーマー)\] タブ

![quartz connector abadf](/mulesoft/current/ja-jp/quartz-connector/latest/_images/quartz-connector-abadf.png)

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 50%;">
<col style="width: 50%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">項目</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>Request Transformer References (要求トランスフォーマー参照)</strong></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">トランスポートに要求を送信する前に要求に適用される同期トランスフォーマーのリストを入力します。</p></td>
</tr>
</tbody>
</table>

## [](#関連情報)関連情報

- XML エディターを使用した Quartz エンドポイントのプロパティの設定についての詳細は、​[「Quartz トランスポートリファレンス」](#3.9@mule-runtime::quartz-transport-reference.adoc)​を参照してください。
- Mule での Quartz の使用については、 [MuleSoft のブログの記事](http://blogs.mulesoft.com/dev/mule-dev/mule-and-quartz-scheduled-jobs-and-long-running-tasks/)​をご覧ください。
- [Quartz のドキュメント](http://quartz-scheduler.org/documentation)​をご覧ください。
- [Poll スコープ](#3.9@mule-runtime::poll-reference.adoc)​についてご確認ください。