panda-server-source 0.8.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- panda_server_source-0.8.0.dist-info/METADATA +55 -0
- panda_server_source-0.8.0.dist-info/RECORD +375 -0
- panda_server_source-0.8.0.dist-info/WHEEL +4 -0
- panda_server_source-0.8.0.dist-info/licenses/LICENSE.txt +202 -0
- pandajedi/__init__.py +0 -0
- pandajedi/jedibrokerage/AtlasAnalJobBroker.py +2343 -0
- pandajedi/jedibrokerage/AtlasBrokerUtils.py +1292 -0
- pandajedi/jedibrokerage/AtlasProdJobBroker.py +2064 -0
- pandajedi/jedibrokerage/AtlasProdTaskBroker.py +629 -0
- pandajedi/jedibrokerage/GenJobBroker.py +381 -0
- pandajedi/jedibrokerage/JobBrokerBase.py +133 -0
- pandajedi/jedibrokerage/TaskBrokerBase.py +15 -0
- pandajedi/jedibrokerage/__init__.py +0 -0
- pandajedi/jediconfig/__init__.py +0 -0
- pandajedi/jediconfig/jedi_config.py +40 -0
- pandajedi/jedicore/FactoryBase.py +182 -0
- pandajedi/jedicore/Interaction.py +433 -0
- pandajedi/jedicore/JediDBProxy.py +56 -0
- pandajedi/jedicore/JediDBProxyPool.py +37 -0
- pandajedi/jedicore/JediDBSchemaInfo.py +17 -0
- pandajedi/jedicore/JediException.py +13 -0
- pandajedi/jedicore/JediTaskBuffer.py +984 -0
- pandajedi/jedicore/JediTaskBufferInterface.py +50 -0
- pandajedi/jedicore/MsgWrapper.py +124 -0
- pandajedi/jedicore/ProcessUtils.py +34 -0
- pandajedi/jedicore/SiteCandidate.py +90 -0
- pandajedi/jedicore/ThreadUtils.py +205 -0
- pandajedi/jedicore/__init__.py +0 -0
- pandajedi/jediddm/AtlasDDMClient.py +1708 -0
- pandajedi/jediddm/DDMClientBase.py +16 -0
- pandajedi/jediddm/DDMInterface.py +83 -0
- pandajedi/jediddm/GenDDMClient.py +17 -0
- pandajedi/jediddm/__init__.py +0 -0
- pandajedi/jedidog/AtlasAnalWatchDog.py +648 -0
- pandajedi/jedidog/AtlasDataCarouselWatchDog.py +189 -0
- pandajedi/jedidog/AtlasDataLocalityUpdaterWatchDog.py +215 -0
- pandajedi/jedidog/AtlasProdWatchDog.py +443 -0
- pandajedi/jedidog/AtlasQueueFillerWatchDog.py +800 -0
- pandajedi/jedidog/AtlasTaskWithholderWatchDog.py +245 -0
- pandajedi/jedidog/AtlasWorkflowManagerWatchDog.py +63 -0
- pandajedi/jedidog/GenWatchDog.py +21 -0
- pandajedi/jedidog/JumboWatchDog.py +147 -0
- pandajedi/jedidog/TypicalWatchDogBase.py +122 -0
- pandajedi/jedidog/WatchDogBase.py +53 -0
- pandajedi/jedidog/__init__.py +0 -0
- pandajedi/jediexec/reniceJEDI.py +25 -0
- pandajedi/jedigen/AtlasTaskGenerator.py +110 -0
- pandajedi/jedigen/TaskGeneratorBase.py +15 -0
- pandajedi/jedigen/__init__.py +0 -0
- pandajedi/jedimsgprocessor/__init__.py +0 -0
- pandajedi/jedimsgprocessor/ai_parameter_adjuster_msg_processor +71 -0
- pandajedi/jedimsgprocessor/atlas_idds_msg_processor.py +66 -0
- pandajedi/jedimsgprocessor/base_msg_processor.py +33 -0
- pandajedi/jedimsgprocessor/forwarding_msg_processor.py +29 -0
- pandajedi/jedimsgprocessor/hpo_msg_processor.py +93 -0
- pandajedi/jedimsgprocessor/jedi_contents_feeder_msg_processor.py +63 -0
- pandajedi/jedimsgprocessor/jedi_job_generator_msg_processor.py +185 -0
- pandajedi/jedimsgprocessor/jedi_post_processor_msg_processor.py +82 -0
- pandajedi/jedimsgprocessor/kafka_msg_processor.py +44 -0
- pandajedi/jedimsgprocessor/panda_callback_msg_processor.py +182 -0
- pandajedi/jedimsgprocessor/panda_to_jedi_msg_processor.py +74 -0
- pandajedi/jedimsgprocessor/processing_msg_processor.py +134 -0
- pandajedi/jedimsgprocessor/status_report_msg_processor.py +129 -0
- pandajedi/jedimsgprocessor/tape_carousel_msg_processor.py +118 -0
- pandajedi/jedimsgprocessor/workflow_manager_msg_processor.py +89 -0
- pandajedi/jediorder/ContentsFeeder.py +785 -0
- pandajedi/jediorder/JediDaemon.py +27 -0
- pandajedi/jediorder/JediKnight.py +55 -0
- pandajedi/jediorder/JediMaster.py +238 -0
- pandajedi/jediorder/JediMsgProcessor.py +32 -0
- pandajedi/jediorder/JobBroker.py +33 -0
- pandajedi/jediorder/JobGenerator.py +2763 -0
- pandajedi/jediorder/JobSplitter.py +308 -0
- pandajedi/jediorder/JobThrottler.py +28 -0
- pandajedi/jediorder/PostProcessor.py +166 -0
- pandajedi/jediorder/TaskBroker.py +268 -0
- pandajedi/jediorder/TaskCommando.py +334 -0
- pandajedi/jediorder/TaskGenerator.py +17 -0
- pandajedi/jediorder/TaskRefiner.py +611 -0
- pandajedi/jediorder/TaskSetupper.py +17 -0
- pandajedi/jediorder/WatchDog.py +79 -0
- pandajedi/jediorder/__init__.py +0 -0
- pandajedi/jedipprocess/AtlasAnalPostProcessor.py +404 -0
- pandajedi/jedipprocess/AtlasPostProcessorUtils.py +50 -0
- pandajedi/jedipprocess/AtlasProdPostProcessor.py +178 -0
- pandajedi/jedipprocess/GenPostProcessor.py +35 -0
- pandajedi/jedipprocess/MailTemplates.py +185 -0
- pandajedi/jedipprocess/PostProcessorBase.py +269 -0
- pandajedi/jedipprocess/__init__.py +0 -0
- pandajedi/jedirefine/AtlasAnalTaskRefiner.py +259 -0
- pandajedi/jedirefine/AtlasProdTaskRefiner.py +162 -0
- pandajedi/jedirefine/GenTaskRefiner.py +61 -0
- pandajedi/jedirefine/RefinerUtils.py +154 -0
- pandajedi/jedirefine/TaskRefinerBase.py +996 -0
- pandajedi/jedirefine/__init__.py +0 -0
- pandajedi/jedisetup/AtlasTaskSetupper.py +309 -0
- pandajedi/jedisetup/GenTaskSetupper.py +16 -0
- pandajedi/jedisetup/SimpleTaskSetupper.py +152 -0
- pandajedi/jedisetup/TaskSetupperBase.py +15 -0
- pandajedi/jedisetup/__init__.py +0 -0
- pandajedi/jeditest/SchemaChecker.py +41 -0
- pandajedi/jeditest/addContWoSoTask.py +54 -0
- pandajedi/jeditest/addDataCarouselRequest.py +47 -0
- pandajedi/jeditest/addEventServiceTask.py +101 -0
- pandajedi/jeditest/addHpoTask.py +81 -0
- pandajedi/jeditest/addIDDSStageInRequest.py +56 -0
- pandajedi/jeditest/addNonAtlasTask.py +71 -0
- pandajedi/jeditest/addNonAtlasTaskEnc.py +64 -0
- pandajedi/jeditest/addTestTask.py +124 -0
- pandajedi/jeditest/addTestTaskParamToDEFT.py +70 -0
- pandajedi/jeditest/addTestTaskWithMerger.py +97 -0
- pandajedi/jeditest/brokerTest.py +78 -0
- pandajedi/jeditest/cancelDataCarouselRequest.py +35 -0
- pandajedi/jeditest/contentsFeederTest.py +28 -0
- pandajedi/jeditest/contentsFeederTestWithTask.py +18 -0
- pandajedi/jeditest/ddmTest.py +4 -0
- pandajedi/jeditest/jobGenForOneTask.py +38 -0
- pandajedi/jeditest/jobGeneratorTest.py +43 -0
- pandajedi/jeditest/jobSplitterTest.py +104 -0
- pandajedi/jeditest/jobThrottlerTest.py +22 -0
- pandajedi/jeditest/msgProcessorTest.py +9 -0
- pandajedi/jeditest/postProcessorTest.py +18 -0
- pandajedi/jeditest/resubmitDataCarouselRequest.py +35 -0
- pandajedi/jeditest/resubmitTaskParam.py +20 -0
- pandajedi/jeditest/taskBrokerTest.py +22 -0
- pandajedi/jeditest/taskBrokerTestWithTask.py +38 -0
- pandajedi/jeditest/taskBufferTest.py +5 -0
- pandajedi/jeditest/taskCommandoTest.py +28 -0
- pandajedi/jeditest/taskRefinerTest.py +30 -0
- pandajedi/jeditest/testOneTaskToRefine.py +49 -0
- pandajedi/jeditest/testOneTaskToTaskBroker.py +42 -0
- pandajedi/jeditest/testPandaDDMMap.py +62 -0
- pandajedi/jeditest/updateDataCarouselRequestParams.py +50 -0
- pandajedi/jeditest/watchDogTest.py +25 -0
- pandajedi/jeditest/workQueueTest.py +22 -0
- pandajedi/jedithrottle/AtlasAnalJobThrottler.py +19 -0
- pandajedi/jedithrottle/AtlasProdJobThrottler.py +18 -0
- pandajedi/jedithrottle/GenJobThrottler.py +26 -0
- pandajedi/jedithrottle/JobThrottlerBase.py +496 -0
- pandajedi/jedithrottle/__init__.py +0 -0
- pandaserver/__init__.py +0 -0
- pandaserver/api/__init__.py +0 -0
- pandaserver/api/v1/__init__.py +0 -0
- pandaserver/api/v1/common.py +339 -0
- pandaserver/api/v1/credential_management_api.py +372 -0
- pandaserver/api/v1/data_carousel_api.py +264 -0
- pandaserver/api/v1/event_api.py +269 -0
- pandaserver/api/v1/file_server_api.py +942 -0
- pandaserver/api/v1/harvester_api.py +445 -0
- pandaserver/api/v1/http_client.py +166 -0
- pandaserver/api/v1/idds_api.py +180 -0
- pandaserver/api/v1/job_api.py +463 -0
- pandaserver/api/v1/metaconfig_api.py +122 -0
- pandaserver/api/v1/pilot_api.py +895 -0
- pandaserver/api/v1/statistics_api.py +207 -0
- pandaserver/api/v1/system_api.py +186 -0
- pandaserver/api/v1/task_api.py +1520 -0
- pandaserver/api/v1/tests/__init__.py +0 -0
- pandaserver/api/v1/tests/credential_management_api_tests.py +116 -0
- pandaserver/api/v1/tests/data_carousel_api_tests.py +82 -0
- pandaserver/api/v1/tests/harvester_api_tests.py +188 -0
- pandaserver/api/v1/tests/idds_api_tests.py +45 -0
- pandaserver/api/v1/tests/job_api_tests.py +112 -0
- pandaserver/api/v1/tests/pilot_api_tests.py +154 -0
- pandaserver/api/v1/tests/statistics_api_tests.py +104 -0
- pandaserver/api/v1/tests/system_api_tests.py +58 -0
- pandaserver/api/v1/tests/task_api_tests.py +590 -0
- pandaserver/api/v1/version.py +2 -0
- pandaserver/api/v1/workflow_api.py +136 -0
- pandaserver/brokerage/SiteMapper.py +406 -0
- pandaserver/brokerage/__init__.py +0 -0
- pandaserver/brokerage/broker.py +272 -0
- pandaserver/config/__init__.py +0 -0
- pandaserver/config/config_utils.py +15 -0
- pandaserver/config/daemon_config.py +29 -0
- pandaserver/config/mcp_config.py +38 -0
- pandaserver/config/panda_config.py +233 -0
- pandaserver/configurator/Carbon.py +65 -0
- pandaserver/configurator/Configurator.py +908 -0
- pandaserver/configurator/__init__.py +0 -0
- pandaserver/configurator/aux.py +73 -0
- pandaserver/daemons/__init__.py +0 -0
- pandaserver/daemons/master.py +110 -0
- pandaserver/daemons/master_systemd.py +79 -0
- pandaserver/daemons/scripts/__init__.py +0 -0
- pandaserver/daemons/scripts/add_main.py +264 -0
- pandaserver/daemons/scripts/add_sub.py +221 -0
- pandaserver/daemons/scripts/cache_pilots.py +47 -0
- pandaserver/daemons/scripts/cache_schedconfig.py +286 -0
- pandaserver/daemons/scripts/carbon.py +50 -0
- pandaserver/daemons/scripts/configurator.py +94 -0
- pandaserver/daemons/scripts/copyArchive.py +1387 -0
- pandaserver/daemons/scripts/datasetManager.py +1154 -0
- pandaserver/daemons/scripts/dummy_test.py +25 -0
- pandaserver/daemons/scripts/evpPD2P.py +144 -0
- pandaserver/daemons/scripts/hs_scrapers.py +264 -0
- pandaserver/daemons/scripts/metric_collector.py +927 -0
- pandaserver/daemons/scripts/panda_activeusers_query.py +80 -0
- pandaserver/daemons/scripts/pilotStreaming.py +109 -0
- pandaserver/daemons/scripts/process_workflow_files_daemon.py +166 -0
- pandaserver/daemons/scripts/recover_lost_files_daemon.py +177 -0
- pandaserver/daemons/scripts/task_evaluator.py +405 -0
- pandaserver/daemons/scripts/tmpwatch.py +70 -0
- pandaserver/daemons/scripts/worker_synchronization.py +97 -0
- pandaserver/daemons/utils.py +753 -0
- pandaserver/dataservice/DataServiceUtils.py +323 -0
- pandaserver/dataservice/ErrorCode.py +25 -0
- pandaserver/dataservice/RecoverLostFilesCore.py +322 -0
- pandaserver/dataservice/__init__.py +0 -0
- pandaserver/dataservice/activator.py +79 -0
- pandaserver/dataservice/adder_atlas_plugin.py +1106 -0
- pandaserver/dataservice/adder_dummy_plugin.py +31 -0
- pandaserver/dataservice/adder_gen.py +954 -0
- pandaserver/dataservice/adder_plugin_base.py +27 -0
- pandaserver/dataservice/adder_result.py +75 -0
- pandaserver/dataservice/adder_simple_plugin.py +160 -0
- pandaserver/dataservice/closer.py +247 -0
- pandaserver/dataservice/closer_atlas_plugin.py +90 -0
- pandaserver/dataservice/ddm.py +1381 -0
- pandaserver/dataservice/ddm_handler.py +95 -0
- pandaserver/dataservice/dyn_data_distributer.py +824 -0
- pandaserver/dataservice/event_lookup_client_ei.py +77 -0
- pandaserver/dataservice/event_picker.py +268 -0
- pandaserver/dataservice/finisher.py +194 -0
- pandaserver/dataservice/setupper.py +225 -0
- pandaserver/dataservice/setupper_atlas_plugin.py +1851 -0
- pandaserver/dataservice/setupper_dummy_plugin.py +47 -0
- pandaserver/dataservice/setupper_plugin_base.py +67 -0
- pandaserver/jobdispatcher/DispatcherUtils.py +35 -0
- pandaserver/jobdispatcher/ErrorCode.py +19 -0
- pandaserver/jobdispatcher/JobDispatcher.py +1625 -0
- pandaserver/jobdispatcher/Protocol.py +443 -0
- pandaserver/jobdispatcher/Watcher.py +186 -0
- pandaserver/jobdispatcher/__init__.py +0 -0
- pandaserver/pandamcp/__init__.py +0 -0
- pandaserver/pandamcp/mcp_main.py +56 -0
- pandaserver/pandamcp/mcp_test_client.py +95 -0
- pandaserver/pandamcp/mcp_utils.py +74 -0
- pandaserver/proxycache/__init__.py +0 -0
- pandaserver/proxycache/panda_proxy_cache.py +240 -0
- pandaserver/proxycache/token_cache.py +141 -0
- pandaserver/server/.gacl +6 -0
- pandaserver/server/panda.py +539 -0
- pandaserver/srvcore/CoreUtils.py +572 -0
- pandaserver/srvcore/MailUtils.py +106 -0
- pandaserver/srvcore/__init__.py +0 -0
- pandaserver/srvcore/allowed_methods.py +100 -0
- pandaserver/srvcore/oidc_utils.py +152 -0
- pandaserver/srvcore/panda_request.py +196 -0
- pandaserver/srvcore/srv_msg_utils.py +42 -0
- pandaserver/taskbuffer/ConBridge.py +513 -0
- pandaserver/taskbuffer/DBProxyPool.py +95 -0
- pandaserver/taskbuffer/DataCarousel.py +3053 -0
- pandaserver/taskbuffer/DatasetSpec.py +137 -0
- pandaserver/taskbuffer/DdmSpec.py +201 -0
- pandaserver/taskbuffer/ErrorCode.py +87 -0
- pandaserver/taskbuffer/EventServiceUtils.py +396 -0
- pandaserver/taskbuffer/FileSpec.py +290 -0
- pandaserver/taskbuffer/GlobalShares.py +244 -0
- pandaserver/taskbuffer/HarvesterMetricsSpec.py +92 -0
- pandaserver/taskbuffer/Initializer.py +82 -0
- pandaserver/taskbuffer/InputChunk.py +1080 -0
- pandaserver/taskbuffer/JediCacheSpec.py +57 -0
- pandaserver/taskbuffer/JediDatasetSpec.py +588 -0
- pandaserver/taskbuffer/JediFileSpec.py +242 -0
- pandaserver/taskbuffer/JediTaskSpec.py +1687 -0
- pandaserver/taskbuffer/JobSpec.py +1006 -0
- pandaserver/taskbuffer/JobUtils.py +232 -0
- pandaserver/taskbuffer/NucleusSpec.py +116 -0
- pandaserver/taskbuffer/OraDBProxy.py +174 -0
- pandaserver/taskbuffer/PanDAMsgProcessor.py +8 -0
- pandaserver/taskbuffer/PandaDBSchemaInfo.py +18 -0
- pandaserver/taskbuffer/ParseJobXML.py +350 -0
- pandaserver/taskbuffer/PickleFileSpec.py +18 -0
- pandaserver/taskbuffer/PickleJobSpec.py +25 -0
- pandaserver/taskbuffer/PrioUtil.py +40 -0
- pandaserver/taskbuffer/ProcessGroups.py +111 -0
- pandaserver/taskbuffer/ResourceSpec.py +175 -0
- pandaserver/taskbuffer/SQLDumper.py +37 -0
- pandaserver/taskbuffer/SQLManager.py +60 -0
- pandaserver/taskbuffer/SiteSpec.py +304 -0
- pandaserver/taskbuffer/SupErrors.py +10 -0
- pandaserver/taskbuffer/TaskBuffer.py +2882 -0
- pandaserver/taskbuffer/TaskBufferInterface.py +163 -0
- pandaserver/taskbuffer/Utils.py +848 -0
- pandaserver/taskbuffer/WorkQueue.py +227 -0
- pandaserver/taskbuffer/WorkQueueMapper.py +203 -0
- pandaserver/taskbuffer/WorkerSpec.py +143 -0
- pandaserver/taskbuffer/WrappedCursor.py +487 -0
- pandaserver/taskbuffer/WrappedPickle.py +88 -0
- pandaserver/taskbuffer/WrappedPostgresConn.py +24 -0
- pandaserver/taskbuffer/__init__.py +0 -0
- pandaserver/taskbuffer/db_proxy_mods/OraDBProxy_structure.png +0 -0
- pandaserver/taskbuffer/db_proxy_mods/__init__.py +7 -0
- pandaserver/taskbuffer/db_proxy_mods/base_module.py +841 -0
- pandaserver/taskbuffer/db_proxy_mods/data_carousel_module.py +772 -0
- pandaserver/taskbuffer/db_proxy_mods/entity_module.py +3804 -0
- pandaserver/taskbuffer/db_proxy_mods/job_complex_module.py +5661 -0
- pandaserver/taskbuffer/db_proxy_mods/job_standalone_module.py +2640 -0
- pandaserver/taskbuffer/db_proxy_mods/metrics_module.py +874 -0
- pandaserver/taskbuffer/db_proxy_mods/misc_standalone_module.py +4272 -0
- pandaserver/taskbuffer/db_proxy_mods/task_complex_module.py +6172 -0
- pandaserver/taskbuffer/db_proxy_mods/task_event_module.py +4953 -0
- pandaserver/taskbuffer/db_proxy_mods/task_standalone_module.py +4999 -0
- pandaserver/taskbuffer/db_proxy_mods/task_utils_module.py +2063 -0
- pandaserver/taskbuffer/db_proxy_mods/worker_module.py +1944 -0
- pandaserver/taskbuffer/db_proxy_mods/workflow_module.py +832 -0
- pandaserver/taskbuffer/retryModule.py +552 -0
- pandaserver/taskbuffer/task_split_rules.py +308 -0
- pandaserver/taskbuffer/workflow_processor.py +249 -0
- pandaserver/taskbuffer/wrapped_oracle_conn.py +18 -0
- pandaserver/test/SchemaChecker.py +40 -0
- pandaserver/test/__init__.py +0 -0
- pandaserver/test/banUser.py +43 -0
- pandaserver/test/boostPrio.py +19 -0
- pandaserver/test/boostUser.py +35 -0
- pandaserver/test/callbackDDM.py +11 -0
- pandaserver/test/daod_on_demand.py +95 -0
- pandaserver/test/finishJob.py +184 -0
- pandaserver/test/finishTaskJEDI.py +11 -0
- pandaserver/test/getJobs.py +53 -0
- pandaserver/test/killJob.py +79 -0
- pandaserver/test/killJobLowPrio.py +99 -0
- pandaserver/test/killJobsInTask.py +56 -0
- pandaserver/test/killTask.py +80 -0
- pandaserver/test/killTaskJEDI.py +11 -0
- pandaserver/test/killUser.py +83 -0
- pandaserver/test/lsst/README.txt +7 -0
- pandaserver/test/lsst/lsstSubmit.py +139 -0
- pandaserver/test/lsst/lsstSubmitMERGEtest.py +141 -0
- pandaserver/test/lsst/lsstSubmitPhosim332.py +53 -0
- pandaserver/test/lsst/prepare-client-tarball-from-bigpanda-server.sh +41 -0
- pandaserver/test/reassignJobs.py +17 -0
- pandaserver/test/reassignSite.py +82 -0
- pandaserver/test/reassignTask.py +117 -0
- pandaserver/test/reassignWaiting.py +39 -0
- pandaserver/test/recoverLostFiles.py +7 -0
- pandaserver/test/reloadInputDS.py +51 -0
- pandaserver/test/sendCommandToJob.py +26 -0
- pandaserver/test/setDebugMode.py +38 -0
- pandaserver/test/setPriority.py +28 -0
- pandaserver/test/testEvgen.py +60 -0
- pandaserver/test/testEvgen17.py +58 -0
- pandaserver/test/testG4sim.py +81 -0
- pandaserver/test/testG4sim17.py +90 -0
- pandaserver/test/testGlobalShares.py +131 -0
- pandaserver/test/testReco.py +103 -0
- pandaserver/test/testSimulReco14.py +98 -0
- pandaserver/test/testSiteMap.py +26 -0
- pandaserver/test/testUpdateWorkerPilotStatus.py +9 -0
- pandaserver/userinterface/Client.py +1686 -0
- pandaserver/userinterface/UserIF.py +1799 -0
- pandaserver/userinterface/__init__.py +0 -0
- pandaserver/workflow/__init__.py +0 -0
- pandaserver/workflow/data_handler_plugins/base_data_handler.py +48 -0
- pandaserver/workflow/data_handler_plugins/ddm_collection_data_handler.py +100 -0
- pandaserver/workflow/data_handler_plugins/panda_task_data_handler.py +140 -0
- pandaserver/workflow/pcwl_test.py +122 -0
- pandaserver/workflow/pcwl_utils.py +384 -0
- pandaserver/workflow/psnakemake_container.json +68 -0
- pandaserver/workflow/psnakemake_task.json +62 -0
- pandaserver/workflow/psnakemake_test.py +60 -0
- pandaserver/workflow/snakeparser/__init__.py +3 -0
- pandaserver/workflow/snakeparser/extensions.py +74 -0
- pandaserver/workflow/snakeparser/log.py +53 -0
- pandaserver/workflow/snakeparser/names.py +3 -0
- pandaserver/workflow/snakeparser/parser.py +332 -0
- pandaserver/workflow/snakeparser/utils.py +29 -0
- pandaserver/workflow/step_handler_plugins/base_step_handler.py +85 -0
- pandaserver/workflow/step_handler_plugins/panda_task_step_handler.py +280 -0
- pandaserver/workflow/workflow_base.py +531 -0
- pandaserver/workflow/workflow_core.py +1974 -0
- pandaserver/workflow/workflow_core_smoketest.py +388 -0
- pandaserver/workflow/workflow_parser.py +222 -0
- pandaserver/workflow/workflow_utils.py +1047 -0
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandacommon.pandalogger.PandaLogger import PandaLogger
|
|
4
|
+
|
|
5
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
6
|
+
from pandajedi.jedicore.MsgWrapper import MsgWrapper
|
|
7
|
+
from pandajedi.jedicore.ThreadUtils import ThreadPool
|
|
8
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
9
|
+
from pandajedi.jediorder.JobBroker import JobBroker
|
|
10
|
+
from pandajedi.jediorder.JobGenerator import JobGeneratorThread
|
|
11
|
+
from pandajedi.jediorder.JobSplitter import JobSplitter
|
|
12
|
+
from pandajedi.jediorder.TaskSetupper import TaskSetupper
|
|
13
|
+
|
|
14
|
+
logger = PandaLogger().getLogger("JobGenerator")
|
|
15
|
+
tmpLog = MsgWrapper(logger)
|
|
16
|
+
|
|
17
|
+
tbIF = JediTaskBufferInterface()
|
|
18
|
+
tbIF.setupInterface()
|
|
19
|
+
|
|
20
|
+
siteMapper = tbIF.get_site_mapper()
|
|
21
|
+
|
|
22
|
+
ddmIF = DDMInterface()
|
|
23
|
+
ddmIF.setupInterface()
|
|
24
|
+
|
|
25
|
+
jediTaskID = int(sys.argv[1])
|
|
26
|
+
|
|
27
|
+
datasetIDs = None
|
|
28
|
+
if len(sys.argv) > 2:
|
|
29
|
+
datasetIDs = [int(sys.argv[2])]
|
|
30
|
+
|
|
31
|
+
s, taskSpec = tbIF.getTaskWithID_JEDI(jediTaskID)
|
|
32
|
+
|
|
33
|
+
cloudName = taskSpec.cloud
|
|
34
|
+
vo = taskSpec.vo
|
|
35
|
+
prodSourceLabel = taskSpec.prodSourceLabel
|
|
36
|
+
queueID = taskSpec.workQueue_ID
|
|
37
|
+
gshare_name = taskSpec.gshare
|
|
38
|
+
|
|
39
|
+
workQueue = tbIF.getWorkQueueMap().getQueueWithID(queueID, gshare_name)
|
|
40
|
+
|
|
41
|
+
threadPool = ThreadPool()
|
|
42
|
+
|
|
43
|
+
# get typical number of files
|
|
44
|
+
# typicalNumFilesMap = tbIF.getTypicalNumInput_JEDI(vo,prodSourceLabel,workQueue,
|
|
45
|
+
# useResultCache=600)
|
|
46
|
+
|
|
47
|
+
typicalNumFilesMap = {}
|
|
48
|
+
|
|
49
|
+
tmpListList = tbIF.getTasksToBeProcessed_JEDI(
|
|
50
|
+
None,
|
|
51
|
+
vo,
|
|
52
|
+
workQueue,
|
|
53
|
+
prodSourceLabel,
|
|
54
|
+
cloudName,
|
|
55
|
+
nFiles=10,
|
|
56
|
+
simTasks=[jediTaskID],
|
|
57
|
+
fullSimulation=True,
|
|
58
|
+
typicalNumFilesMap=typicalNumFilesMap,
|
|
59
|
+
simDatasets=datasetIDs,
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
taskSetupper = TaskSetupper(vo, prodSourceLabel)
|
|
63
|
+
taskSetupper.initializeMods(tbIF, ddmIF)
|
|
64
|
+
|
|
65
|
+
for dummyID, tmpList in tmpListList:
|
|
66
|
+
for taskSpec, cloudName, inputChunk in tmpList:
|
|
67
|
+
jobBroker = JobBroker(taskSpec.vo, taskSpec.prodSourceLabel)
|
|
68
|
+
tmpStat = jobBroker.initializeMods(ddmIF.getInterface(vo), tbIF)
|
|
69
|
+
splitter = JobSplitter()
|
|
70
|
+
gen = JobGeneratorThread(None, threadPool, tbIF, ddmIF, siteMapper, False, taskSetupper, None, None, "dummy", None, None)
|
|
71
|
+
|
|
72
|
+
taskParamMap = None
|
|
73
|
+
if taskSpec.useLimitedSites():
|
|
74
|
+
tmpStat, taskParamMap = gen.readTaskParams(taskSpec, taskParamMap, tmpLog)
|
|
75
|
+
|
|
76
|
+
tmpStat, inputChunk = jobBroker.doBrokerage(taskSpec, cloudName, inputChunk, taskParamMap)
|
|
77
|
+
|
|
78
|
+
# tmpStat,subChunks = splitter.doSplit(taskSpec,inputChunk,siteMapper)
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
4
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
5
|
+
from pandajedi.jedirefine import RefinerUtils
|
|
6
|
+
from pandaserver.taskbuffer.DataCarousel import DataCarouselInterface
|
|
7
|
+
|
|
8
|
+
vo = "atlas"
|
|
9
|
+
request_id = int(sys.argv[1])
|
|
10
|
+
|
|
11
|
+
print("set tbIF")
|
|
12
|
+
tbIF = JediTaskBufferInterface()
|
|
13
|
+
tbIF.setupInterface(max_size=1)
|
|
14
|
+
|
|
15
|
+
print("set ddmIF")
|
|
16
|
+
ddmIF = DDMInterface()
|
|
17
|
+
ddmIF.setupInterface()
|
|
18
|
+
|
|
19
|
+
print("set DCIF")
|
|
20
|
+
data_carousel_interface = DataCarouselInterface(tbIF, ddmIF.getInterface(vo))
|
|
21
|
+
if data_carousel_interface is None:
|
|
22
|
+
# data carousel interface is undefined
|
|
23
|
+
errStr = f"data carousel interface is undefined for vo={vo}"
|
|
24
|
+
print(errStr)
|
|
25
|
+
sys.exit(1)
|
|
26
|
+
|
|
27
|
+
print(f"cancel request_id={request_id}")
|
|
28
|
+
ret = data_carousel_interface.cancel_request(request_id)
|
|
29
|
+
|
|
30
|
+
if not ret:
|
|
31
|
+
# failed to cancel
|
|
32
|
+
print(f"failed; got {ret}")
|
|
33
|
+
else:
|
|
34
|
+
# cancelled
|
|
35
|
+
print(f"cancelled, got {ret}")
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
try:
|
|
4
|
+
testTaskType = sys.argv[1]
|
|
5
|
+
except Exception:
|
|
6
|
+
testTaskType = "test"
|
|
7
|
+
|
|
8
|
+
try:
|
|
9
|
+
vo = sys.argv[2]
|
|
10
|
+
except Exception:
|
|
11
|
+
vo = "atlas"
|
|
12
|
+
|
|
13
|
+
import multiprocessing
|
|
14
|
+
|
|
15
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
16
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
17
|
+
from pandajedi.jediorder import ContentsFeeder
|
|
18
|
+
|
|
19
|
+
tbIF = JediTaskBufferInterface()
|
|
20
|
+
tbIF.setupInterface()
|
|
21
|
+
|
|
22
|
+
ddmIF = DDMInterface()
|
|
23
|
+
ddmIF.setupInterface()
|
|
24
|
+
|
|
25
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
26
|
+
|
|
27
|
+
contentsFeeder = multiprocessing.Process(target=ContentsFeeder.launcher, args=(child_conn, tbIF, ddmIF, vo, testTaskType))
|
|
28
|
+
contentsFeeder.start()
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
4
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
5
|
+
from pandajedi.jediorder.ContentsFeeder import ContentsFeederThread
|
|
6
|
+
|
|
7
|
+
jedi_task_id = int(sys.argv[1])
|
|
8
|
+
|
|
9
|
+
tbIF = JediTaskBufferInterface()
|
|
10
|
+
tbIF.setupInterface()
|
|
11
|
+
|
|
12
|
+
ddmIF = DDMInterface()
|
|
13
|
+
ddmIF.setupInterface()
|
|
14
|
+
|
|
15
|
+
task_ds_list = tbIF.getDatasetsToFeedContents_JEDI(task_id=jedi_task_id, force_read=True)
|
|
16
|
+
|
|
17
|
+
c = ContentsFeederThread(taskDsList=None, threadPool=None, taskbufferIF=tbIF, ddmIF=ddmIF, pid="")
|
|
18
|
+
c.feed_contents_to_tasks(task_ds_list, real_run=False)
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import os
|
|
2
|
+
import socket
|
|
3
|
+
import sys
|
|
4
|
+
|
|
5
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
6
|
+
from pandajedi.jedicore.ThreadUtils import ListWithLock, ThreadPool
|
|
7
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
8
|
+
from pandajedi.jediorder.JobGenerator import JobGeneratorThread
|
|
9
|
+
from pandajedi.jediorder.TaskSetupper import TaskSetupper
|
|
10
|
+
|
|
11
|
+
tbIF = JediTaskBufferInterface()
|
|
12
|
+
tbIF.setupInterface()
|
|
13
|
+
|
|
14
|
+
siteMapper = tbIF.get_site_mapper()
|
|
15
|
+
|
|
16
|
+
ddmIF = DDMInterface()
|
|
17
|
+
ddmIF.setupInterface()
|
|
18
|
+
|
|
19
|
+
jediTaskID = int(sys.argv[1])
|
|
20
|
+
|
|
21
|
+
# get task attributes
|
|
22
|
+
s, taskSpec = tbIF.getTaskWithID_JEDI(jediTaskID)
|
|
23
|
+
pid = f"{socket.getfqdn().split('.')[0]}-{os.getpid()}_{os.getpgrp()}-sgen"
|
|
24
|
+
vo = taskSpec.vo
|
|
25
|
+
prodSourceLabel = taskSpec.prodSourceLabel
|
|
26
|
+
workQueue = tbIF.getWorkQueueMap().getQueueWithIDGshare(taskSpec.workQueue_ID, taskSpec.gshare)
|
|
27
|
+
|
|
28
|
+
# get inputs
|
|
29
|
+
tmpList = tbIF.getTasksToBeProcessed_JEDI(pid, None, workQueue, None, None, nFiles=1000, target_tasks=[jediTaskID])
|
|
30
|
+
inputList = ListWithLock(tmpList)
|
|
31
|
+
|
|
32
|
+
# create thread
|
|
33
|
+
threadPool = ThreadPool()
|
|
34
|
+
taskSetupper = TaskSetupper(vo, prodSourceLabel)
|
|
35
|
+
taskSetupper.initializeMods(tbIF, ddmIF)
|
|
36
|
+
gen = JobGeneratorThread(inputList, threadPool, tbIF, ddmIF, siteMapper, True, taskSetupper, pid, workQueue, "sgen", None, None, None, False)
|
|
37
|
+
gen.start()
|
|
38
|
+
gen.join()
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import multiprocessing
|
|
2
|
+
import sys
|
|
3
|
+
|
|
4
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
5
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
6
|
+
from pandajedi.jediorder import JobGenerator
|
|
7
|
+
|
|
8
|
+
tbIF = JediTaskBufferInterface()
|
|
9
|
+
tbIF.setupInterface()
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
ddmIF = DDMInterface()
|
|
13
|
+
ddmIF.setupInterface()
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
17
|
+
|
|
18
|
+
try:
|
|
19
|
+
testVO = sys.argv[1]
|
|
20
|
+
except Exception:
|
|
21
|
+
testVO = "atlas"
|
|
22
|
+
|
|
23
|
+
try:
|
|
24
|
+
testTaskType = sys.argv[2]
|
|
25
|
+
except Exception:
|
|
26
|
+
testTaskType = "test"
|
|
27
|
+
|
|
28
|
+
try:
|
|
29
|
+
execJob = False
|
|
30
|
+
if sys.argv[3] == "y":
|
|
31
|
+
execJob = True
|
|
32
|
+
except Exception:
|
|
33
|
+
pass
|
|
34
|
+
|
|
35
|
+
try:
|
|
36
|
+
testClouds = sys.argv[4].split(",")
|
|
37
|
+
except Exception:
|
|
38
|
+
testClouds = [None]
|
|
39
|
+
|
|
40
|
+
print(f"{testVO} {testTaskType} {testClouds}")
|
|
41
|
+
|
|
42
|
+
gen = multiprocessing.Process(target=JobGenerator.launcher, args=(child_conn, tbIF, ddmIF, testVO, testTaskType, testClouds, False, execJob, None, True))
|
|
43
|
+
gen.start()
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore import Interaction
|
|
4
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
5
|
+
from pandajedi.jedicore.MsgWrapper import MsgWrapper
|
|
6
|
+
from pandajedi.jedicore.ThreadUtils import ListWithLock, ThreadPool
|
|
7
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
8
|
+
from pandajedi.jediorder.JobBroker import JobBroker
|
|
9
|
+
from pandajedi.jediorder.JobGenerator import JobGeneratorThread, logger
|
|
10
|
+
from pandajedi.jediorder.JobSplitter import JobSplitter
|
|
11
|
+
from pandajedi.jediorder.TaskSetupper import TaskSetupper
|
|
12
|
+
|
|
13
|
+
tmpLog = MsgWrapper(logger)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
tbIF = JediTaskBufferInterface()
|
|
17
|
+
tbIF.setupInterface()
|
|
18
|
+
|
|
19
|
+
siteMapper = tbIF.get_site_mapper()
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
ddmIF = DDMInterface()
|
|
23
|
+
ddmIF.setupInterface()
|
|
24
|
+
|
|
25
|
+
jediTaskID = int(sys.argv[1])
|
|
26
|
+
try:
|
|
27
|
+
datasetID = [int(sys.argv[2])]
|
|
28
|
+
except Exception:
|
|
29
|
+
datasetID = None
|
|
30
|
+
try:
|
|
31
|
+
n_files = int(sys.argv[3])
|
|
32
|
+
except Exception:
|
|
33
|
+
n_files = 10
|
|
34
|
+
|
|
35
|
+
s, taskSpec = tbIF.getTaskWithID_JEDI(jediTaskID)
|
|
36
|
+
|
|
37
|
+
cloudName = taskSpec.cloud
|
|
38
|
+
vo = taskSpec.vo
|
|
39
|
+
prodSourceLabel = taskSpec.prodSourceLabel
|
|
40
|
+
queueID = taskSpec.workQueue_ID
|
|
41
|
+
gshare_name = taskSpec.gshare
|
|
42
|
+
|
|
43
|
+
workQueue = tbIF.getWorkQueueMap().getQueueWithIDGshare(queueID, gshare_name)
|
|
44
|
+
|
|
45
|
+
brokerageLockIDs = ListWithLock([])
|
|
46
|
+
|
|
47
|
+
threadPool = ThreadPool()
|
|
48
|
+
|
|
49
|
+
# get typical number of files
|
|
50
|
+
typicalNumFilesMap = tbIF.getTypicalNumInput_JEDI(vo, prodSourceLabel, workQueue, useResultCache=600)
|
|
51
|
+
|
|
52
|
+
tmpListList = tbIF.getTasksToBeProcessed_JEDI(
|
|
53
|
+
None,
|
|
54
|
+
vo,
|
|
55
|
+
workQueue,
|
|
56
|
+
prodSourceLabel,
|
|
57
|
+
cloudName,
|
|
58
|
+
nFiles=n_files,
|
|
59
|
+
simTasks=[jediTaskID],
|
|
60
|
+
fullSimulation=True,
|
|
61
|
+
typicalNumFilesMap=typicalNumFilesMap,
|
|
62
|
+
simDatasets=datasetID,
|
|
63
|
+
numNewTaskWithJumbo=5,
|
|
64
|
+
ignore_lock=True,
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
taskSetupper = TaskSetupper(vo, prodSourceLabel)
|
|
68
|
+
taskSetupper.initializeMods(tbIF, ddmIF)
|
|
69
|
+
|
|
70
|
+
resource_types = tbIF.load_resource_types()
|
|
71
|
+
|
|
72
|
+
for dummyID, tmpList in tmpListList:
|
|
73
|
+
task_common = {}
|
|
74
|
+
for taskSpec, cloudName, inputChunk in tmpList:
|
|
75
|
+
jobBroker = JobBroker(taskSpec.vo, taskSpec.prodSourceLabel)
|
|
76
|
+
tmpStat = jobBroker.initializeMods(ddmIF.getInterface(vo), tbIF)
|
|
77
|
+
jobBrokerCore = jobBroker.getImpl(taskSpec.vo, taskSpec.prodSourceLabel)
|
|
78
|
+
jobBrokerCore.setTestMode()
|
|
79
|
+
jobBrokerCore.set_task_common_dict(task_common)
|
|
80
|
+
splitter = JobSplitter()
|
|
81
|
+
gen = JobGeneratorThread(
|
|
82
|
+
None, threadPool, tbIF, ddmIF, siteMapper, False, taskSetupper, None, None, "dummy", None, None, brokerageLockIDs, False, resource_types
|
|
83
|
+
)
|
|
84
|
+
gen.time_profile_level = 1
|
|
85
|
+
|
|
86
|
+
taskParamMap = None
|
|
87
|
+
if taskSpec.useLimitedSites():
|
|
88
|
+
tmpStat, taskParamMap = gen.readTaskParams(taskSpec, taskParamMap, tmpLog)
|
|
89
|
+
jobBroker.setLockID(taskSpec.vo, taskSpec.prodSourceLabel, 123, 0)
|
|
90
|
+
tmpStat, inputChunk = jobBroker.doBrokerage(taskSpec, cloudName, inputChunk, taskParamMap)
|
|
91
|
+
brokerageLockID = jobBroker.getBaseLockID(taskSpec.vo, taskSpec.prodSourceLabel)
|
|
92
|
+
if brokerageLockID is not None:
|
|
93
|
+
brokerageLockIDs.append(brokerageLockID)
|
|
94
|
+
for brokeragelockID in brokerageLockIDs:
|
|
95
|
+
tbIF.unlockProcessWithPID_JEDI(taskSpec.vo, taskSpec.prodSourceLabel, workQueue.queue_id, brokeragelockID, True)
|
|
96
|
+
tmpStat, subChunks, isSkipped = splitter.doSplit(taskSpec, inputChunk, siteMapper, allow_chunk_size_limit=True)
|
|
97
|
+
if tmpStat == Interaction.SC_SUCCEEDED and isSkipped:
|
|
98
|
+
# run again without chunk size limit to generate jobs for skipped snippet
|
|
99
|
+
tmpStat, tmpChunks, isSkipped = splitter.doSplit(taskSpec, inputChunk, siteMapper, allow_chunk_size_limit=False)
|
|
100
|
+
if tmpStat == Interaction.SC_SUCCEEDED:
|
|
101
|
+
subChunks += tmpChunks
|
|
102
|
+
tmpStat, pandaJobs, datasetToRegister, oldPandaIDs, parallelOutMap, outDsMap = gen.doGenerate(
|
|
103
|
+
taskSpec, cloudName, subChunks, inputChunk, tmpLog, True, splitter=splitter
|
|
104
|
+
)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
2
|
+
from pandajedi.jediorder.JobThrottler import JobThrottler
|
|
3
|
+
|
|
4
|
+
tbIF = JediTaskBufferInterface()
|
|
5
|
+
tbIF.setupInterface()
|
|
6
|
+
|
|
7
|
+
vo = "atlas"
|
|
8
|
+
prodSourceLabel = "managed"
|
|
9
|
+
cloud = "WORLD"
|
|
10
|
+
|
|
11
|
+
# get SiteMapper
|
|
12
|
+
siteMapper = tbIF.get_site_mapper()
|
|
13
|
+
wqMap = tbIF.getWorkQueueMap()
|
|
14
|
+
|
|
15
|
+
jt = JobThrottler(vo, prodSourceLabel)
|
|
16
|
+
jt.initializeMods(tbIF)
|
|
17
|
+
|
|
18
|
+
workQueues = wqMap.getAlignedQueueList(vo, prodSourceLabel)
|
|
19
|
+
resource_types = tbIF.load_resource_types()
|
|
20
|
+
for workQueue in workQueues:
|
|
21
|
+
for resource_type in resource_types:
|
|
22
|
+
print(jt.toBeThrottled(vo, prodSourceLabel, cloud, workQueue, resource_type.resource_name))
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import multiprocessing
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
4
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
5
|
+
from pandajedi.jediorder import PostProcessor
|
|
6
|
+
|
|
7
|
+
tbIF = JediTaskBufferInterface()
|
|
8
|
+
tbIF.setupInterface()
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
ddmIF = DDMInterface()
|
|
12
|
+
ddmIF.setupInterface()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
16
|
+
|
|
17
|
+
postProcessor = multiprocessing.Process(target=PostProcessor.launcher, args=(child_conn, tbIF, ddmIF))
|
|
18
|
+
postProcessor.start()
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
4
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
5
|
+
from pandajedi.jedirefine import RefinerUtils
|
|
6
|
+
from pandaserver.taskbuffer.DataCarousel import DataCarouselInterface
|
|
7
|
+
|
|
8
|
+
vo = "atlas"
|
|
9
|
+
request_id = int(sys.argv[1])
|
|
10
|
+
|
|
11
|
+
print("set tbIF")
|
|
12
|
+
tbIF = JediTaskBufferInterface()
|
|
13
|
+
tbIF.setupInterface(max_size=1)
|
|
14
|
+
|
|
15
|
+
print("set ddmIF")
|
|
16
|
+
ddmIF = DDMInterface()
|
|
17
|
+
ddmIF.setupInterface()
|
|
18
|
+
|
|
19
|
+
print("set DCIF")
|
|
20
|
+
data_carousel_interface = DataCarouselInterface(tbIF, ddmIF.getInterface(vo))
|
|
21
|
+
if data_carousel_interface is None:
|
|
22
|
+
# data carousel interface is undefined
|
|
23
|
+
errStr = f"data carousel interface is undefined for vo={vo}"
|
|
24
|
+
print(errStr)
|
|
25
|
+
sys.exit(1)
|
|
26
|
+
|
|
27
|
+
print(f"resubmit for request_id={request_id}")
|
|
28
|
+
dc_req_spec_resubmitted, _ = data_carousel_interface.resubmit_request(request_id)
|
|
29
|
+
|
|
30
|
+
if not dc_req_spec_resubmitted:
|
|
31
|
+
# failed to resubmit
|
|
32
|
+
print(f"failed; got {dc_req_spec_resubmitted}")
|
|
33
|
+
else:
|
|
34
|
+
# resubmitted
|
|
35
|
+
print(f"resubmitted; new request_id={dc_req_spec_resubmitted.request_id}")
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from taskbuffer.Initializer import initializer
|
|
4
|
+
|
|
5
|
+
from pandajedi.jedicore import JediTaskBuffer
|
|
6
|
+
|
|
7
|
+
jediTaskID = sys.argv[1]
|
|
8
|
+
|
|
9
|
+
# initialize DB using dummy connection
|
|
10
|
+
initializer.init()
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
taskBuffer = JediTaskBuffer.JediTaskBuffer(None)
|
|
14
|
+
proxy = taskBuffer.proxyPool.getProxy()
|
|
15
|
+
|
|
16
|
+
s, o = proxy.getClobObj("select task_param from atlas_deft.deft_task where task_id=:task_id", {":task_id": jediTaskID})
|
|
17
|
+
|
|
18
|
+
taskParamStr = o[0][0]
|
|
19
|
+
|
|
20
|
+
proxy.insertTaskParams_JEDI(None, taskParamStr)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import multiprocessing
|
|
2
|
+
import sys
|
|
3
|
+
|
|
4
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
5
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
6
|
+
from pandajedi.jediorder import TaskBroker
|
|
7
|
+
|
|
8
|
+
try:
|
|
9
|
+
testTaskType = sys.argv[1]
|
|
10
|
+
except Exception:
|
|
11
|
+
testTaskType = "test"
|
|
12
|
+
|
|
13
|
+
tbIF = JediTaskBufferInterface()
|
|
14
|
+
tbIF.setupInterface()
|
|
15
|
+
|
|
16
|
+
ddmIF = DDMInterface()
|
|
17
|
+
ddmIF.setupInterface()
|
|
18
|
+
|
|
19
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
20
|
+
|
|
21
|
+
taskBroker = multiprocessing.Process(target=TaskBroker.launcher, args=(child_conn, tbIF, ddmIF, "atlas", testTaskType))
|
|
22
|
+
taskBroker.start()
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.FactoryBase import FactoryBase
|
|
4
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
5
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
6
|
+
from pandajedi.jediorder.TaskBroker import TaskBroker
|
|
7
|
+
|
|
8
|
+
tbIF = JediTaskBufferInterface()
|
|
9
|
+
tbIF.setupInterface()
|
|
10
|
+
|
|
11
|
+
siteMapper = tbIF.get_site_mapper()
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
ddmIF = DDMInterface()
|
|
15
|
+
ddmIF.setupInterface()
|
|
16
|
+
|
|
17
|
+
jedi_task_id = int(sys.argv[1])
|
|
18
|
+
|
|
19
|
+
s, task_spec = tbIF.getTaskWithID_JEDI(jedi_task_id)
|
|
20
|
+
|
|
21
|
+
vo = task_spec.vo
|
|
22
|
+
prodSourceLabel = task_spec.prodSourceLabel
|
|
23
|
+
resource_type = task_spec.resource_type
|
|
24
|
+
queue_id = task_spec.workQueue_ID
|
|
25
|
+
gshare_name = task_spec.gshare
|
|
26
|
+
|
|
27
|
+
work_queue = tbIF.getWorkQueueMap().getQueueWithIDGshare(queue_id, gshare_name)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
task_list = tbIF.getTasksToBeProcessed_JEDI(None, None, None, None, None, simTasks=[jedi_task_id], readMinFiles=True, fullSimulation=True)
|
|
31
|
+
for ts in task_list:
|
|
32
|
+
for t in ts[1]:
|
|
33
|
+
t[0].nucleus = None
|
|
34
|
+
|
|
35
|
+
task_broker = TaskBroker(None, tbIF, ddmIF, [vo], [prodSourceLabel])
|
|
36
|
+
FactoryBase.initializeMods(task_broker, task_broker.taskBufferIF, task_broker.ddmIF)
|
|
37
|
+
impl = task_broker.getImpl(vo, prodSourceLabel)
|
|
38
|
+
impl.doBrokerage(task_list, vo, prodSourceLabel, work_queue, resource_type)
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import multiprocessing
|
|
2
|
+
|
|
3
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
4
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
5
|
+
from pandajedi.jediorder import TaskCommando
|
|
6
|
+
|
|
7
|
+
tbIF = JediTaskBufferInterface()
|
|
8
|
+
tbIF.setupInterface()
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
ddmIF = DDMInterface()
|
|
12
|
+
ddmIF.setupInterface()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
16
|
+
|
|
17
|
+
try:
|
|
18
|
+
testVO = sys.argv[1]
|
|
19
|
+
except Exception:
|
|
20
|
+
testVO = "any"
|
|
21
|
+
|
|
22
|
+
try:
|
|
23
|
+
testTaskType = sys.argv[2]
|
|
24
|
+
except Exception:
|
|
25
|
+
testTaskType = "any"
|
|
26
|
+
|
|
27
|
+
taskCommando = multiprocessing.Process(target=TaskCommando.launcher, args=(child_conn, tbIF, ddmIF, testVO, testTaskType))
|
|
28
|
+
taskCommando.start()
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
try:
|
|
4
|
+
testTaskType = sys.argv[1]
|
|
5
|
+
except Exception:
|
|
6
|
+
testTaskType = "test"
|
|
7
|
+
|
|
8
|
+
try:
|
|
9
|
+
vo = sys.argv[2]
|
|
10
|
+
except Exception:
|
|
11
|
+
vo = "atlas"
|
|
12
|
+
|
|
13
|
+
import multiprocessing
|
|
14
|
+
|
|
15
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
16
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
17
|
+
from pandajedi.jediorder import TaskRefiner
|
|
18
|
+
|
|
19
|
+
tbIF = JediTaskBufferInterface()
|
|
20
|
+
tbIF.setupInterface()
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
ddmIF = DDMInterface()
|
|
24
|
+
ddmIF.setupInterface()
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
parent_conn, child_conn = multiprocessing.Pipe()
|
|
28
|
+
|
|
29
|
+
taskRefiner = multiprocessing.Process(target=TaskRefiner.launcher, args=(child_conn, tbIF, ddmIF, vo, testTaskType))
|
|
30
|
+
taskRefiner.start()
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandacommon.pandalogger.PandaLogger import PandaLogger
|
|
4
|
+
|
|
5
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
6
|
+
from pandajedi.jedicore.MsgWrapper import MsgWrapper
|
|
7
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
8
|
+
from pandajedi.jediorder.TaskRefiner import TaskRefiner
|
|
9
|
+
from pandajedi.jedirefine import RefinerUtils
|
|
10
|
+
|
|
11
|
+
logger = PandaLogger().getLogger("TaskRefiner")
|
|
12
|
+
tmpLog = MsgWrapper(logger)
|
|
13
|
+
|
|
14
|
+
tbIF = JediTaskBufferInterface()
|
|
15
|
+
tbIF.setupInterface()
|
|
16
|
+
|
|
17
|
+
siteMapper = tbIF.get_site_mapper()
|
|
18
|
+
|
|
19
|
+
ddmIF = DDMInterface()
|
|
20
|
+
ddmIF.setupInterface()
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
jediTaskID = int(sys.argv[1])
|
|
24
|
+
|
|
25
|
+
s, taskSpec = tbIF.getTaskWithID_JEDI(jediTaskID)
|
|
26
|
+
refiner = TaskRefiner(None, tbIF, ddmIF, taskSpec.vo, taskSpec.prodSourceLabel)
|
|
27
|
+
refiner.initializeMods(tbIF, ddmIF)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
taskParam = tbIF.getTaskParamsWithID_JEDI(jediTaskID)
|
|
31
|
+
taskParamMap = RefinerUtils.decodeJSON(taskParam)
|
|
32
|
+
|
|
33
|
+
vo = taskParamMap["vo"]
|
|
34
|
+
prodSourceLabel = taskParamMap["prodSourceLabel"]
|
|
35
|
+
taskType = taskParamMap["taskType"]
|
|
36
|
+
|
|
37
|
+
cloudName = taskSpec.cloud
|
|
38
|
+
vo = taskSpec.vo
|
|
39
|
+
prodSourceLabel = taskSpec.prodSourceLabel
|
|
40
|
+
queueID = taskSpec.workQueue_ID
|
|
41
|
+
gshare_name = taskSpec.gshare
|
|
42
|
+
|
|
43
|
+
impl = refiner.instantiateImpl(vo, prodSourceLabel, taskType, tbIF, ddmIF)
|
|
44
|
+
|
|
45
|
+
workQueueMapper = tbIF.getWorkQueueMap()
|
|
46
|
+
|
|
47
|
+
impl.initializeRefiner(tmpLog)
|
|
48
|
+
impl.extractCommon(jediTaskID, taskParamMap, workQueueMapper, taskSpec.splitRule)
|
|
49
|
+
impl.doRefine(jediTaskID, taskParamMap)
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from pandacommon.pandalogger.PandaLogger import PandaLogger
|
|
4
|
+
|
|
5
|
+
from pandajedi.jedicore.JediTaskBufferInterface import JediTaskBufferInterface
|
|
6
|
+
from pandajedi.jedicore.MsgWrapper import MsgWrapper
|
|
7
|
+
from pandajedi.jediddm.DDMInterface import DDMInterface
|
|
8
|
+
from pandajedi.jediorder.TaskBroker import TaskBroker
|
|
9
|
+
from pandajedi.jedirefine import RefinerUtils
|
|
10
|
+
|
|
11
|
+
logger = PandaLogger().getLogger("TaskBroker")
|
|
12
|
+
tmpLog = MsgWrapper(logger)
|
|
13
|
+
|
|
14
|
+
tbIF = JediTaskBufferInterface()
|
|
15
|
+
tbIF.setupInterface()
|
|
16
|
+
|
|
17
|
+
siteMapper = tbIF.get_site_mapper()
|
|
18
|
+
|
|
19
|
+
ddmIF = DDMInterface()
|
|
20
|
+
ddmIF.setupInterface()
|
|
21
|
+
|
|
22
|
+
jediTaskID = int(sys.argv[1])
|
|
23
|
+
|
|
24
|
+
s, taskSpec = tbIF.getTaskWithID_JEDI(jediTaskID, False)
|
|
25
|
+
body = TaskBroker(None, tbIF, ddmIF, taskSpec.vo, taskSpec.prodSourceLabel)
|
|
26
|
+
body.initializeMods(tbIF, ddmIF)
|
|
27
|
+
|
|
28
|
+
taskParam = tbIF.getTaskParamsWithID_JEDI(jediTaskID)
|
|
29
|
+
taskParamMap = RefinerUtils.decodeJSON(taskParam)
|
|
30
|
+
|
|
31
|
+
vo = taskParamMap["vo"]
|
|
32
|
+
prodSourceLabel = taskParamMap["prodSourceLabel"]
|
|
33
|
+
taskType = taskParamMap["taskType"]
|
|
34
|
+
|
|
35
|
+
workQueueMapper = tbIF.getWorkQueueMap()
|
|
36
|
+
workQueue = workQueueMapper.getQueueWithIDGshare(taskSpec.workQueue_ID, taskSpec.gshare)
|
|
37
|
+
|
|
38
|
+
impl = body.getImpl(vo, prodSourceLabel)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
tmpListItem = tbIF.getTasksToBeProcessed_JEDI(None, None, None, None, None, simTasks=[jediTaskID], readMinFiles=True)
|
|
42
|
+
impl.doBrokerage(tmpListItem, taskSpec.vo, taskSpec.prodSourceLabel, workQueue, taskSpec.resource_type)
|