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

Using ToastedMarshmallow #26

Open
Rishi321 opened this issue Nov 19, 2020 · 1 comment
Open

Using ToastedMarshmallow #26

Rishi321 opened this issue Nov 19, 2020 · 1 comment
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested

Comments

@Rishi321
Copy link

Original question on Flapison: multimeric/flapison#22

Has this library been tested with ToastedMarshmallow?
We have been using this library to great effect recently in a project (for about 8 months), but we're now seeing some performance hits during the Marshmallow serialization (sometimes 100's of ms) when dealing with many objects (100's)

I've seen people talk about ToastedMarshmallow and notice that the compute_schema recreates schema instances everytime, according to the ToastedMarshmallow documentation this will reduce the gain heavily.

Is there a reason we recreate schema objects every time? If not, what would be the best way to change the code to allow one schema object per resource?

I tried changing the code and using an in-memory object dict as an object cache, but toastedmarshmallow still made no performance impact.
Anybody tried this before?

Also posted here: miLibris#192

@mahenzon mahenzon added enhancement New feature or request help wanted Extra attention is needed question Further information is requested labels Nov 25, 2020
@mahenzon
Copy link
Collaborator

Hi! If you already have any code to provide for us to check, please do it.

I think we can make optional use of custom lib, so we can add some kind of flag to show the lib that we are using some custom implementation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants