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

Added support for nested schemas with resolveuid block deserializer #1595

Merged
merged 13 commits into from May 17, 2023

Conversation

JeffersonBledsoe
Copy link
Member

@JeffersonBledsoe JeffersonBledsoe commented Mar 6, 2023

As the initial implementation only iterated over the smart field, there may be a performance impact with this PR with very large blocks as there is no way of knowing if a nested value will have a smart field without iterating through them all. Any comments on this/ input on if this could be improved are welcomed!

Closes #1594

@mister-roboto
Copy link

@JeffersonBledsoe thanks for creating this Pull Request and helping to improve Plone!

TL;DR: Finish pushing changes, pass all other checks, then paste a comment:

@jenkins-plone-org please run jobs

To ensure that these changes do not break other parts of Plone, the Plone test suite matrix needs to pass, but it takes 30-60 min. Other CI checks are usually much faster and the Plone Jenkins resources are limited, so when done pushing changes and all other checks pass either start all Jenkins PR jobs yourself, or simply add the comment above in this PR to start all the jobs automatically.

Happy hacking!

@netlify
Copy link

netlify bot commented Mar 6, 2023

👷 Deploy Preview for plone-restapi processing.

Name Link
🔨 Latest commit 80e2597
🔍 Latest deploy log https://app.netlify.com/sites/plone-restapi/deploys/64067dbffe804a0008103ebf

@netlify
Copy link

netlify bot commented Mar 6, 2023

Deploy Preview for plone-restapi canceled.

Name Link
🔨 Latest commit 5958997
🔍 Latest deploy log https://app.netlify.com/sites/plone-restapi/deploys/646383c0b937460008cf68bc

@JeffersonBledsoe JeffersonBledsoe changed the title WIP: Support for nested schemas with resolveuid deserializer WIP: Added support for nested schemas with resolveuid deserializer Mar 6, 2023
@JeffersonBledsoe
Copy link
Member Author

@jenkins-plone-org please run jobs

@JeffersonBledsoe JeffersonBledsoe marked this pull request as ready for review March 7, 2023 00:28
@JeffersonBledsoe JeffersonBledsoe changed the title WIP: Added support for nested schemas with resolveuid deserializer WIP: Added support for nested schemas with resolveuid block deserializer Mar 7, 2023
@JeffersonBledsoe JeffersonBledsoe changed the title WIP: Added support for nested schemas with resolveuid block deserializer Added support for nested schemas with resolveuid block deserializer Mar 7, 2023
@JeffersonBledsoe
Copy link
Member Author

@tisto Thoughts on this? David expressed some concerns in #1594

@JeffersonBledsoe
Copy link
Member Author

@jenkins-plone-org please run jobs

@davisagli
Copy link
Sponsor Member

@JeffersonBledsoe @razvanMiu I tested this with a large page from one of our projects and don't see any significant difference in performance.

I think sub-blocks will end up getting processed twice, since the (de)serializer will be called once for the subblock and again for the top-level block, and the second one will recurse down into the subblocks. That's not necessarily a problem, but could be optimized in the future.

@davisagli davisagli merged commit d40e0bf into master May 17, 2023
20 checks passed
@davisagli davisagli deleted the resolveuid-deserializer-improvements branch May 17, 2023 20:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

resolveuid deserializer doesn't handle lists or nested dicts
5 participants