X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=application%2Fhub%2Fmain%2Ffilter%2Ftask%2Fcruncher%2Fclass_CruncherTaskHandlerInitializerFilter.php;h=b4ef8b4e00a62f77355514e274e4fcdf2f7da8b5;hb=a9c315c022840a31e051201a61078dcde368f389;hp=9091574d6675c481ca02917b48c28a44b90aadfa;hpb=7a24172126f93445f8aec12e4299d7a5efaecf6f;p=hub.git diff --git a/application/hub/main/filter/task/cruncher/class_CruncherTaskHandlerInitializerFilter.php b/application/hub/main/filter/task/cruncher/class_CruncherTaskHandlerInitializerFilter.php index 9091574d6..b4ef8b4e0 100644 --- a/application/hub/main/filter/task/cruncher/class_CruncherTaskHandlerInitializerFilter.php +++ b/application/hub/main/filter/task/cruncher/class_CruncherTaskHandlerInitializerFilter.php @@ -4,7 +4,7 @@ * * @author Roland Haeder * @version 0.0.0 - * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2011 Cruncher Developer Team + * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2012 Cruncher Developer Team * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org * @@ -21,7 +21,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -class CruncherTaskHandlerInitializerFilter extends BaseFilter implements Filterable { +class CruncherTaskHandlerInitializerFilter extends BaseCruncherFilter implements Filterable { /** * Protected constructor * @@ -62,6 +62,7 @@ class CruncherTaskHandlerInitializerFilter extends BaseFilter implements Filtera $handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class'); // Register all tasks: + // // 1) A task for fetching WUs (work units) or test units $taskInstance = ObjectFactory::createObjectByConfiguredName('cruncher_work_unit_fetcher_task_class'); $handlerInstance->registerTask('cruncher_work_unit_fetcher', $taskInstance); @@ -74,6 +75,14 @@ class CruncherTaskHandlerInitializerFilter extends BaseFilter implements Filtera $taskInstance = ObjectFactory::createObjectByConfiguredName('cruncher_test_unit_producer_task_class'); $handlerInstance->registerTask('cruncher_test_unit_producer', $taskInstance); + /* + * 3) A task for generating keys based on the generated test unit. This + * task will only be executed if the state of the cruncher is one of + * these: 'virgin'. + */ + $taskInstance = ObjectFactory::createObjectByConfiguredName('cruncher_key_producer_task_class'); + $handlerInstance->registerTask('cruncher_key_producer', $taskInstance); + // Put the task handler in registry Registry::getRegistry()->addInstance('task', $handlerInstance); }