Closed svonworl closed 1 week ago
Failed conditions
70.4% Coverage on New Code (required ≥ 80%)
Attention: Patch coverage is 66.66667%
with 16 lines
in your changes missing coverage. Please review.
Project coverage is 74.32%. Comparing base (
b881d9c
) to head (92f4e65
). Report is 1 commits behind head on develop.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Description While investigating https://ucsc-cgl.atlassian.net/browse/SEAB-6448 and https://ucsc-cgl.atlassian.net/browse/SEAB-6449, it appeared beneficial to make some tweaks to TransactionHelper.
Accordingly, this PR improves TransactionHelper to make it more flexible and easy to use, as follows:
transaction()
method that returns a value produced by some user-supplied code.continueSession()
method that instructs the nexttransaction()
method call to not to clear the Session's entities, allowing multiple successive transactions to use the same managed entities, rather than have to "reload" them in each transaction.TransactionHelperException
and rethrow. Removethrown()
and code which used that idiom.To demonstrate the new TransactionHelper
transaction()
method that returns a value, I used it to simplify the portion of the push processing code where we link the "version update" transaction to the "doi generation" transaction. Whilst doing so, I noticed a small bug: if the DOI generation code threw, two LambdaEvents would be logged, one a success, and the other, a failure. This PR fixes said bug.Review Instructions Register a workflow via the
.dockstore.yml
path, and make sure the workflow appears correctly in Dockstore.Issue https://ucsc-cgl.atlassian.net/browse/SEAB-6448 https://ucsc-cgl.atlassian.net/browse/SEAB-6449
Security and Privacy
If there are any concerns that require extra attention from the security team, highlight them here and check the box when complete.
e.g. Does this change...
Please make sure that you've checked the following before submitting your pull request. Thanks!
mvn clean install
@RolesAllowed
annotation