Manual:copyJobQueue.php

From mediawiki.org
This page is a translated version of the page Manual:CopyJobQueue.php and the translation is 67% complete.
MediaWiki バージョン:
1.22

詳細

copyJobQueue.php ファイルは、あるジョブ キュー システムから別のジョブ キュー システムへすべてのジョブをコピーするメンテナンス スクリプトです。

This script requires setting $wgJobQueueMigrationConfig before running. This script processes 500 items in a batch.


The $wgJobQueueMigrationConfig configuration variable consists of keys with array values. These array values are passed to JobQueue::factory(). The parameters in the array should not have wiki or type settings as it will be injected by script itself.

$wgJobQueueMigrationConfig = [
    'db' => [
        'class' => 'JobQueueDB',
        'idGenerator' => 'uniqueId1'
    ],
    'redis' => [
        'class' => 'JobQueueRedis',
        'redisServer' => 'localhost',
        'redisConfig' => [ 'connectTimeout' => 1 ],
        'idGenerator' => 'uniqueId2'
    ]
];

オプション/引数

Option Description Required?
--src Key to $wgJobQueueMigrationConfig for source 必須
--dst Key to $wgJobQueueMigrationConfig for destination 必須
--type Types of jobs to copy (use "all" for all) 必須

使用法

php maintenance/copyJobQueue.php --src scrKey --dst dstKey --type jobType


Terminal

関連項目