-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move EventSetup module PSet validation to be called from ComponentMaker #39556
Conversation
The python configuration system always injects @module_label.
…DescriptionFiller
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Dr15Jones @wddgit What do you think?
@@ -78,12 +78,13 @@ namespace edm { | |||
|
|||
// ---------- member functions --------------------------- | |||
|
|||
protected: | |||
static const std::string kEmpty; | |||
static const std::string kBaseForService; | |||
static const std::string kBaseForESSource; | |||
static const std::string kBaseForESProducer; | |||
static const std::string kBaseForEDLooper; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe there is a better way than making these public? Although maybe it isn't too bad either?
(in the Event system the EDModule base classes define the corresponding strings)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to use constexpr std::string_view for this to avoid allocation when the shared library is loaded? [Although many implementations of std::string have a small string optimization]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds plausible, but I'd leave that to a subsequent PR because of being somewhat orthogonal.
+code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-39556/32345
|
A new Pull Request was created by @makortel (Matti Kortelainen) for master. It involves the following packages:
@cmsbuild, @smuzaffar, @Dr15Jones, @makortel can you please review it and eventually sign? Thanks. cms-bot commands are listed here |
@cmsbuild, please test |
I took a quick look. It all looks reasonable to me. |
-1 Failed Tests: UnitTests Unit TestsI found errors in the following unit tests: ---> test createDBObjecs had ERRORS ---> test GeometryTrackerGeometryBuilderTestDriver had ERRORS ---> test testPhase2SkimmedGeometry had ERRORS ---> test testPhase2PixelNtuple had ERRORS and more ... Comparison Summary@slava77 comparisons for the following workflows were not done due to missing matrix map:
Summary:
|
done with comments |
This change is motivated by ModuleTypeResolver functionality, which, on the EventSetup side, currently misses the PSet validation plugin factory. On the Event side the PSet validation is done as part of the module maker, and this particular change makes the module creation on EventSetup and Event sides a little bit more consistent.
b17d5d8
to
7a302e0
Compare
Pull request #39556 was updated. @cmsbuild, @smuzaffar, @Dr15Jones, @makortel can you please check and sign again. |
@cmsbuild, please test |
-1 Failed Tests: UnitTests RelVals-INPUT Unit TestsI found errors in the following unit tests: ---> test createDBObjecs had ERRORS ---> test materialBudgetHGCalPlots had ERRORS RelVals-INPUTThe relvals timed out after 4 hours. Comparison Summary@slava77 comparisons for the following workflows were not done due to missing matrix map:
Summary:
|
@cmsbuild, please test |
please test
|
+1 Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-db8483/28076/summary.html Comparison Summary@slava77 comparisons for the following workflows were not done due to missing matrix map:
Summary:
|
+1 |
This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @perrotta, @dpiparo, @rappoccio (and backports should be raised in the release meeting by the corresponding L2) |
+1 |
PR description:
The #39391 missed the detail that in the EventSetup the PSet validation is done via a separate plugin factory.
This PR attempts to address that deficiency by moving the PSet validation to be called from the ComponentMaker, just before the ES module is constructed. A benefit of this approach is that it makes the EventSetup side a little bit more consistent with the Event side. A downside is that more code gets mutable access to the PSet (there could be more I didn't think of).
An alternative would be to extend the module type resolving logic in some way to
edm::eventsetup::validateEventSetupParameters()
. In a later PR I'll change thecmssw/FWCore/Framework/interface/resolveMaker.h
Line 16 in 8e73e83
to handle the insertion of the found maker into the caches in
Factory
/ComponentFactory
(in order to cache based on the resolved module type rather than the requested module type), and while handling this non-cached plugin can be added there with some complexity, I felt the approach of this PR to be simpler in the bigger picture.PR validation:
Framework unit tests pass.