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

Improve performance of analysis verification #2643

Merged
merged 10 commits into from
Nov 26, 2024
Merged

Conversation

ramonski
Copy link
Contributor

@ramonski ramonski commented Nov 14, 2024

Description of the issue/feature this PR addresses

This PR speeds up the verification process from 2-3 seconds to 0.5 seconds ~200ms to ~125ms per Analysis.

Current behavior before PR

The after_verify WF event handler tries to transition the parent sample after each analysis verification to verified.

Desired behavior after PR is merged

The after_verify WF event handler checks first if all Analyses are in the state verified before trying to transition the parent to verified

--
I confirm I have tested this PR thoroughly and coded it according to PEP8
and Plone's Python styleguide standards.

@ramonski
Copy link
Contributor Author

ramonski commented Nov 15, 2024

Current Verification Timings per Analysis

Improved Verification Timings per Analysis

@ramonski ramonski marked this pull request as draft November 15, 2024 09:09
@ramonski
Copy link
Contributor Author

Some further improvement can be achieved with this change in senaite.app.listing: senaite/senaite.app.listing#146

@ramonski ramonski marked this pull request as ready for review November 15, 2024 09:54
Copy link
Member

@xispa xispa left a comment

Choose a reason for hiding this comment

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

Awesome, thanks!

@xispa xispa merged commit 3858edd into 2.x Nov 26, 2024
2 checks passed
@xispa xispa deleted the speed-up-analysis-verification branch November 26, 2024 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

2 participants