Skip to content

Commit 53c34a6

Browse files
authored
Merge pull request #49019 from israr100/cfi_fix_csc
Provide fillDescriptions to CSC ESproducers for HLT
2 parents 17320aa + e9a6f4d commit 53c34a6

File tree

4 files changed

+22
-4
lines changed

4 files changed

+22
-4
lines changed

CalibMuon/CSCCalibration/interface/CSCChannelMapperESProducer.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#include <memory>
55

66
#include "FWCore/Framework/interface/ESProducer.h"
7+
#include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h" // for fillDescriptions
78

89
#include "CalibMuon/CSCCalibration/interface/CSCChannelMapperBase.h"
910
#include "CalibMuon/CSCCalibration/interface/CSCChannelMapperRecord.h"
@@ -17,6 +18,8 @@ class CSCChannelMapperESProducer : public edm::ESProducer {
1718

1819
BSP_TYPE produce(const CSCChannelMapperRecord &);
1920

21+
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions);
22+
2023
private:
2124
std::string algoName;
2225
};

CalibMuon/CSCCalibration/interface/CSCIndexerESProducer.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#include <memory>
55

66
#include "FWCore/Framework/interface/ESProducer.h"
7+
#include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h" // needed for fillDescriptions
78

89
#include "CalibMuon/CSCCalibration/interface/CSCIndexerBase.h"
910
#include "CalibMuon/CSCCalibration/interface/CSCIndexerRecord.h"
@@ -17,6 +18,8 @@ class CSCIndexerESProducer : public edm::ESProducer {
1718

1819
BSP_TYPE produce(const CSCIndexerRecord &);
1920

21+
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions);
22+
2023
private:
2124
std::string algoName;
2225
};

CalibMuon/CSCCalibration/plugins/CSCChannelMapperESProducer.cc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
#include "FWCore/Framework/interface/ModuleFactory.h"
2-
32
#include "CalibMuon/CSCCalibration/interface/CSCChannelMapperESProducer.h"
43
#include "CalibMuon/CSCCalibration/interface/CSCChannelMapperFactory.h"
5-
64
#include "FWCore/MessageLogger/interface/MessageLogger.h"
5+
#include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
76

87
CSCChannelMapperESProducer::CSCChannelMapperESProducer(const edm::ParameterSet &pset) {
98
algoName = pset.getParameter<std::string>("AlgoName");
@@ -21,5 +20,12 @@ CSCChannelMapperESProducer::BSP_TYPE CSCChannelMapperESProducer::produce(const C
2120
return CSCChannelMapperESProducer::BSP_TYPE(CSCChannelMapperFactory::get()->create(algoName));
2221
}
2322

23+
// ---- add this ----
24+
void CSCChannelMapperESProducer::fillDescriptions(edm::ConfigurationDescriptions &descriptions) {
25+
edm::ParameterSetDescription desc;
26+
desc.add<std::string>("AlgoName", "CSCChannelMapperStartup"); // default
27+
descriptions.addWithDefaultLabel(desc);
28+
}
29+
2430
// define this as a plug-in
2531
DEFINE_FWK_EVENTSETUP_MODULE(CSCChannelMapperESProducer);

CalibMuon/CSCCalibration/plugins/CSCIndexerESProducer.cc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
#include "FWCore/Framework/interface/ModuleFactory.h"
2-
32
#include "CalibMuon/CSCCalibration/interface/CSCIndexerESProducer.h"
43
#include "CalibMuon/CSCCalibration/interface/CSCIndexerFactory.h"
5-
64
#include "FWCore/MessageLogger/interface/MessageLogger.h"
5+
#include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
76

87
CSCIndexerESProducer::CSCIndexerESProducer(const edm::ParameterSet &pset) {
98
algoName = pset.getParameter<std::string>("AlgoName");
@@ -21,5 +20,12 @@ CSCIndexerESProducer::BSP_TYPE CSCIndexerESProducer::produce(const CSCIndexerRec
2120
return CSCIndexerESProducer::BSP_TYPE(CSCIndexerFactory::get()->create(algoName));
2221
}
2322

23+
// ---- add this ----
24+
void CSCIndexerESProducer::fillDescriptions(edm::ConfigurationDescriptions &descriptions) {
25+
edm::ParameterSetDescription desc;
26+
desc.add<std::string>("AlgoName", "CSCIndexerStartup"); // default
27+
descriptions.addWithDefaultLabel(desc);
28+
}
29+
2430
// define this as a plug-in
2531
DEFINE_FWK_EVENTSETUP_MODULE(CSCIndexerESProducer);

0 commit comments

Comments
 (0)