39 if (objectKey.empty()) {
40 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
"Key is empty";
42 throw std::runtime_error(
"SummaryForFunctionManager: uGMT | Faulty | Empty objectKey");
44 edm::LogError(
"L1-O2O: L1TMuonGlobalParams") <<
"returning unmodified prototype of L1TMuonGlobalParams";
45 return std::make_unique<const L1TMuonGlobalParams>(baseSettings);
49 std::string tscKey = objectKey.substr(0, objectKey.find(
":"));
50 std::string rsKey = objectKey.substr(objectKey.find(
":") + 1, std::string::npos);
53 <<
"Producing L1TMuonGlobalParams with TSC key =" << tscKey <<
" and RS key = " << rsKey;
57 std::map<std::string, std::string> rs_payloads, algo_payloads;
59 std::map<std::string, std::string>
keys =
61 algo_key =
keys[
"ALGO"];
66 std::map<std::string, std::string> rsKeys =
69 std::map<std::string, std::string> algoKeys =
72 for (
auto &
key : rsKeys)
73 rs_payloads[
key.second] =
76 for (
auto &
key : algoKeys)
77 algo_payloads[
key.second] =
79 }
catch (std::runtime_error &
e) {
80 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
e.what();
82 throw std::runtime_error(
"SummaryForFunctionManager: uGMT | Faulty | Broken key");
84 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
"returning unmodified prototype of L1TMuonGlobalParams";
85 return std::make_unique<const L1TMuonGlobalParams>(baseSettings);
95 for (
auto &conf : rs_payloads) {
100 for (
auto &conf : algo_payloads) {
116 for (
auto &conf : algo_payloads) {
120 for (
auto &conf : rs_payloads) {
125 }
catch (std::runtime_error &
e) {
126 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
e.what();
128 throw std::runtime_error(
"SummaryForFunctionManager: uGMT | Faulty | Cannot parse XMLs");
130 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
"returning unmodified prototype of L1TMuonGlobalParams";
131 return std::make_unique<const L1TMuonGlobalParams>(baseSettings);
138 }
catch (std::runtime_error &
e) {
139 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
e.what();
141 throw std::runtime_error(
"SummaryForFunctionManager: uGMT | Faulty | Cannot run helper");
143 edm::LogError(
"L1-O2O: L1TMuonGlobalParamsOnlineProd") <<
"returning unmodified prototype of L1TMuonGlobalParams";
144 return std::make_unique<const L1TMuonGlobalParams>(baseSettings);
151 <<
"SummaryForFunctionManager: uGMT | OK | All looks good";