Skip to content
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

Enforce consumes interface in output modules #13600

Merged

Conversation

wmtan
Copy link
Contributor

@wmtan wmtan commented Mar 4, 2016

Output modules currently have direct access to EventPrincipal, RunPrincipal, and LuminosityBlockPrincipal. Calls to getByLabel() or getForOutput() functions of Principal bypass the consumes interface, so missing consumes calls will not be detected. This PR modifies output modules so that they do not access Principals directly. Rather, they use new classes EventForOutput, LuminosityBlockForOutput, and RunForOutput, similar to the Event, LuminosityBlock, and Run classes used by other modules. Furthermore, reading data is done only by getByToken(), so the consumes interface is enforced everywhere. getByToken() is the only get method supported by the new classes.

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 4, 2016

A new Pull Request was created by @wmtan for CMSSW_8_1_X.

It involves the following packages:

DQMServices/FwkIO
DQMServices/StreamerIO
DataFormats/Common
DataFormats/Provenance
EventFilter/Utilities
FWCore/Framework
FWCore/Modules
IOPool/Input
IOPool/Output
IOPool/Streamer
Mixing/Base

@smuzaffar, @civanch, @Dr15Jones, @cvuosalo, @emeschi, @mdhildreth, @cmsbuild, @deguio, @slava77, @mommsen, @vanbesien, @davidlange6 can you please review it and eventually sign? Thanks.
@makortel, @Martin-Grunewald, @barvic, @wddgit this is something you requested to watch as well.
@slava77, @Degano, @smuzaffar you are the release manager for this.

cms-bot commands are list here #13028

@Dr15Jones
Copy link
Contributor

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 4, 2016

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/11719/console

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 4, 2016

-1

Tested at: 2134fd5
I found errors in the following unit tests:

---> test runtestRecoLocalCaloHGCalRecProducers had ERRORS
---> test runtestTqafTopEventSelection had ERRORS
---> test runtestSimCalorimetryHGCalSimProducers had ERRORS

you can see the results of the tests here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-13600/11719/summary.html

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 5, 2016

@wmtan
Copy link
Contributor Author

wmtan commented Mar 5, 2016

@cmsbuild The three failing unit tests fail in the base IB. The failures have nothing to do with this PR.

@deguio
Copy link
Contributor

deguio commented Mar 7, 2016

please test

@deguio
Copy link
Contributor

deguio commented Mar 7, 2016

+1

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 7, 2016

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/11755/console

@wmtan
Copy link
Contributor Author

wmtan commented Mar 9, 2016

@cmsbuild @Dr15Jones The test failures appear to have nothing to do with this PR. The runtestTqafTopEventSelection test fails in the base IB. The TestRunnerPhysicsToolsCondLiteIO test runs successfully in my work area with this PR, although I am running on a slightly older IB.
Also, the error in TestRunnerPhysicsToolsCondLiteIO appears to have no connection to anything I changed. I will investigate further, however, just to be safe.

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 9, 2016

@wmtan
Copy link
Contributor Author

wmtan commented Mar 9, 2016

@cmsbuild @Dr15Jones OK, I ran the failing TestRunnerPhysicsToolsCondLiteIO with this PR against the latest IB, CMSSW_8_1_X_2016-03-09-1100, and the test passed. I cannot reproduce this test failure. So neither unit test failure is related to this PR.

}
}

bool const fastCloning = (branchType == InEvent) && (whyNotFastClonable_ == FileBlock::CanFastClone);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can only fast clone events?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I see that was in the original logic.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Dr15Jones A decision was made a long time ago to never fast copy anything in the run or lumi trees. It makes life a lot simpler.

@Dr15Jones
Copy link
Contributor

Done with next review

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 9, 2016

Pull request #13600 was updated. @smuzaffar, @civanch, @Dr15Jones, @cvuosalo, @emeschi, @mdhildreth, @cmsbuild, @deguio, @slava77, @mommsen, @vanbesien, @davidlange6 can you please check and sign again.

@wmtan
Copy link
Contributor Author

wmtan commented Mar 9, 2016

Incorporated latest comments from Chris Jones. Should be all done now.

@wmtan
Copy link
Contributor Author

wmtan commented Mar 9, 2016

@cmsbuild please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 9, 2016

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/11810/console

@cmsbuild
Copy link
Contributor

-1

Tested at: 1abdfce
I found errors in the following unit tests:

---> test runtestTqafTopEventSelection had ERRORS

you can see the results of the tests here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-13600/11810/summary.html

@cmsbuild
Copy link
Contributor

davidlange6 added a commit that referenced this pull request Mar 10, 2016
Enforce consumes interface in output modules
@davidlange6 davidlange6 merged commit 1032df4 into cms-sw:CMSSW_8_1_X Mar 10, 2016
@wmtan wmtan deleted the ConsumesInterfaceForOutputModules branch March 16, 2016 22:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants