Definition at line 437 of file o2olib.py.
References cond::CoralServiceWrapperBase.create(), cond::persistency::ITagTable.create(), cond::CoralServiceWrapper< T >.create(), cond::persistency::GLOBAL_TAG::Table.create(), cond::persistency::TAG::Table.create(), cond::CoralServiceFactory.create(), converter::helper::ConcreteCreator.create(), cond::persistency::IPayloadTable.create(), converter::helper::PolymorphicCreator.create(), cond::persistency::IIOVTable.create(), cond::persistency::RUN_INFO::Table.create(), cond::persistency::GLOBAL_TAG_MAP::Table.create(), cond::persistency::PAYLOAD::Table.create(), cond::persistency::GTSchema.create(), cond::persistency::ITagMigrationTable.create(), cond::persistency::RunInfoSchema.create(), cond::persistency::IPayloadMigrationTable.create(), cond::persistency::ITagLogTable.create(), cond::persistency::IIOVSchema.create(), tkal_create_file_lists.FileListCreator.create(), cond::persistency::IGTTable.create(), cond::persistency::IGTMapTable.create(), cond::persistency::IOV::Table.create(), cond::persistency::IGTSchema.create(), cond::persistency::IRunInfoTable.create(), cond::persistency::TAG_LOG::Table.create(), cond::persistency::IRunInfoSchema.create(), cond::persistency::IOVSchema.create(), o2olib.O2OTool.create(), o2olib.O2OTool.disable(), o2olib.O2OTool.dumpConf(), core.PileUpAnalyzer.PileUpAnalyzer.enable, o2olib.O2OTool.enable(), o2olib.O2OTool.listConf(), o2olib.O2OJobMgr.listJobs(), o2olib.O2OTool.listJobs(), o2olib.O2OTool.migrate(), splitter.FileObj.run, uploader.FileObj.run, uploadPayloads.FileObj.run, RPCRunIOV::RunIOV_Item.run, beamspot::BeamSpotContainer.run, TB06Reco.run, TB06RecoH2.run, RPCDQMObject.run, MultiEventFilter::Event.run, DTCalibrationWorker.DTCalibrationWorker.run(), cond::Utilities.run(), L1Analysis::L1AnalysisEventDataFormat.run, PFEGammaToCandidateRemapper.run(), TrackInfoProducerAlgorithm.run(), SurveyAlignmentAlgorithm.run(), generateEDF.LumiInfo.run, lumi::Lumi2DB::LumiSource.run, MuonMillepedeAlgorithm.run(), Type1PFMET.run(), EfficiencyPlotter.run, WZInterestingEventSelector::event.run, MuonDTLocalMillepedeAlgorithm.run(), crabWrapper.CrabWrapper.run(), HIPAlignmentAlgorithm.run(), Point.run, options.ConnectionHLTMenu.run, MuonRecoTest.run, DTWorkflow.DTWorkflow.run(), DTResolutionAnalysisTest.run, BeamSpotRcdReader::theBSfromDB.run, MatacqProducer::MatacqEventId.run, CSCOverlapsAlignmentAlgorithm.run(), DTBlockedROChannelsTest.run, DTDataIntegrityTest.run, DTChamberEfficiencyTest.run, DTResolutionTest.run, ApeSettingAlgorithm.run(), ME::Header.run, ConstantStepOdeSolver.run(), DTEfficiencyTest.run, MillePedeAlignmentAlgorithm.run(), MuonAlignmentFromReference.run(), personalPlayback.Playback.run, DQMNet::CoreObject.run, MatrixUtil.InputInfo.run, DTLocalTriggerBaseTest.run, HitEff.run, EcalDeadCellDeltaRFilter.run, QIE8Simulator.run(), AlignmentAlgorithmBase.run(), cond::RunInfo_t.run, SiPixelErrorEstimation.run, personalPlayback.FrameworkJob.run, SiPixelTrackingRecHitsValid.run, o2olib.O2OTool.run(), dqm_interfaces.DirWalkerFile.run, JsonOutputProducer::JsonEvent.run, SummaryOutputProducer.run, SummaryOutputProducer::Event.run, o2olib.O2OJobMgr.setConfig(), o2olib.O2OTool.setConfig(), o2olib.O2OJobMgr.setInterval(), o2olib.O2OTool.setInterval(), HBHERecalibration.setup(), event.Event.setup, EcalGeomPhiSymHelper.setup(), HcalTPGScale.setup(), CaloTPGTranscoderULUT.setup(), CastorPedestalAnalysis.setup(), HcalPedestalAnalysis.setup(), CandCombinerBase< OutputCollection, CandPtr >.setup(), mps_alisetup.SetupAlignment.setup(), querying.connection.setup(), NamedCandCombinerBase.setup(), NamedCandCombiner< Selector, PairSelector, Cloner, Setup >.setup(), looper.Looper.setup, CandCombiner< Selector, PairSelector, Cloner, OutputCollection, Setup >.setup(), options.HLTProcessOptions.setup, o2olib.O2OTool.setup(), and HcalObjRepresent::ADataRepr.setup().
438 parser = argparse.ArgumentParser(description=
'CMS o2o command-line tool. For general help (manual page), use the help subcommand.')
439 parser.add_argument(
'--db', type=str, help=
'The target database: pro ( for prod ) or dev ( for prep ). default=pro')
440 parser.add_argument(
"--auth",
"-a", type=str, help=
"The path of the authentication file")
441 parser.add_argument(
'--verbose',
'-v', action=
'count', help=
'The verbosity level')
442 parser_subparsers = parser.add_subparsers(title=
'Available subcommands')
443 parser_create = parser_subparsers.add_parser(
'create', description=
'Create a new O2O job')
444 parser_create.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
445 parser_create.add_argument(
'--configFile',
'-c', type=str, help=
'the JSON configuration file path',required=
True)
446 parser_create.add_argument(
'--interval',
'-i', type=int, help=
'the chron job interval',default=0)
447 parser_create.set_defaults(func=self.
create)
448 parser_setConfig = parser_subparsers.add_parser(
'setConfig', description=
'Set a new configuration for the specified job. The configuration is expected as a list of entries "param": "value" (dictionary). The "param" labels will be used to inject the values in the command to execute. The dictionary is stored in JSON format.')
449 parser_setConfig.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
450 parser_setConfig.add_argument(
'--configFile',
'-c', type=str, help=
'the JSON configuration file path',required=
True)
451 parser_setConfig.set_defaults(func=self.
setConfig)
452 parser_setInterval = parser_subparsers.add_parser(
'setInterval',description=
'Set a new execution interval for the specified job')
453 parser_setInterval.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
454 parser_setInterval.add_argument(
'--interval',
'-i', type=int, help=
'the chron job interval',required=
True)
455 parser_setInterval.set_defaults(func=self.
setInterval)
456 parser_enable = parser_subparsers.add_parser(
'enable',description=
'enable the O2O job')
457 parser_enable.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
458 parser_enable.set_defaults(func=self.
enable)
459 parser_disable = parser_subparsers.add_parser(
'disable',description=
'disable the O2O job')
460 parser_disable.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
461 parser_disable.set_defaults(func=self.
disable)
462 parser_migrateConf = parser_subparsers.add_parser(
'migrateConfig',description=
'migrate the tag info for the jobs in configuration entries')
463 parser_migrateConf.set_defaults(func=self.
migrate)
464 parser_listJobs = parser_subparsers.add_parser(
'listJobs', description=
'list the registered jobs')
465 parser_listJobs.set_defaults(func=self.
listJobs)
466 parser_listConf = parser_subparsers.add_parser(
'listConfig', description=
'shows the configurations for the specified job')
467 parser_listConf.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
468 parser_listConf.add_argument(
'--dump', type=int, help=
'Dump the specified config.',default=0)
469 parser_listConf.set_defaults(func=self.
listConf)
470 parser_dumpConf = parser_subparsers.add_parser(
'dumpConfig', description=
'dumps a specific job configuration version')
471 parser_dumpConf.add_argument(
'versionIndex', type=str,help=
'the version to dump')
472 parser_dumpConf.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
473 parser_dumpConf.add_argument(
'--configFile',
'-c', type=str, help=
'the JSON configuration file name - default:[jobname]_[version].json')
474 parser_dumpConf.set_defaults(func=self.
dumpConf)
475 parser_run = parser_subparsers.add_parser(
'run', description=
'Wrapper for O2O jobs execution. Supports input parameter injection from the configuration file associated to the job. The formatting syntax supported are the python ones: "command -paramName {paramLabel}" or "command -paramName %(paramLabel)s". where [paramName] is the name of the parameter required for the command, and [paramLabel] is the key of the parameter entry in the config dictionary (recommended to be equal for clarity!"')
476 parser_run.add_argument(
'executable', type=str,help=
'command to execute')
477 parser_run.add_argument(
'--name',
'-n', type=str, help=
'The o2o job name',required=
True)
478 parser_run.set_defaults(func=self.
run)
480 args = parser.parse_args()
488 sys.exit( args.func())
489 except Exception
as e: