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(), converter::helper::PolymorphicCreator.create(), cond::persistency::RUN_INFO::Table.create(), cond::persistency::IPayloadTable.create(), cond::persistency::GLOBAL_TAG_MAP::Table.create(), cond::persistency::IIOVTable.create(), cond::persistency::RunInfoSchema.create(), cond::persistency::PAYLOAD::Table.create(), cond::persistency::GTSchema.create(), cond::persistency::ITagMigrationTable.create(), tkal_create_file_lists.FileListCreator.create(), cond::persistency::IPayloadMigrationTable.create(), cond::persistency::ITagLogTable.create(), cond::persistency::IOV::Table.create(), cond::persistency::IIOVSchema.create(), cond::persistency::IGTTable.create(), cond::persistency::IGTMapTable.create(), cond::persistency::TAG_LOG::Table.create(), cond::persistency::IGTSchema.create(), cond::persistency::IOVSchema.create(), cond::persistency::IRunInfoTable.create(), cond::persistency::IRunInfoSchema.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(), L1Analysis::L1AnalysisEventDataFormat.run, cond::Utilities.run(), TrackInfoProducerAlgorithm.run(), PFEGammaToCandidateRemapper.run(), SurveyAlignmentAlgorithm.run(), MuonMillepedeAlgorithm.run(), EfficiencyPlotter.run, lumi::Lumi2DB::LumiSource.run, Type1PFMET.run(), generateEDF.LumiInfo.run, WZInterestingEventSelector::event.run, MuonRecoTest.run, MuonDTLocalMillepedeAlgorithm.run(), crabWrapper.CrabWrapper.run(), HIPAlignmentAlgorithm.run(), DTResolutionAnalysisTest.run, options.ConnectionHLTMenu.run, DTWorkflow.DTWorkflow.run(), Point.run, MatacqProducer::MatacqEventId.run, BeamSpotRcdReader::theBSfromDB.run, DTBlockedROChannelsTest.run, DTDataIntegrityTest.run, CSCOverlapsAlignmentAlgorithm.run(), DTChamberEfficiencyTest.run, DTResolutionTest.run, ConstantStepOdeSolver.run(), ME::Header.run, DTEfficiencyTest.run, ApeSettingAlgorithm.run(), MuonAlignmentFromReference.run(), MillePedeAlignmentAlgorithm.run(), personalPlayback.Playback.run, DQMNet::CoreObject.run, DTLocalTriggerBaseTest.run, MatrixUtil.InputInfo.run, HitEff.run, QIE8Simulator.run(), EcalDeadCellDeltaRFilter.run, cond::RunInfo_t.run, AlignmentAlgorithmBase.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(), EcalGeomPhiSymHelper.setup(), event.Event.setup, HcalTPGScale.setup(), HcalPedestalAnalysis.setup(), CastorPedestalAnalysis.setup(), CaloTPGTranscoderULUT.setup(), NamedCandCombinerBase.setup(), mps_alisetup.SetupAlignment.setup(), querying.connection.setup(), CandCombinerBase< OutputCollection, CandPtr >.setup(), CandCombiner< Selector, PairSelector, Cloner, OutputCollection, Setup >.setup(), NamedCandCombiner< Selector, PairSelector, Cloner, Setup >.setup(), looper.Looper.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: