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

[Question] Mapper performance recommendations #146

Open
rsavuliak-macpaw opened this issue Sep 24, 2024 · 1 comment
Open

[Question] Mapper performance recommendations #146

rsavuliak-macpaw opened this issue Sep 24, 2024 · 1 comment

Comments

@rsavuliak-macpaw
Copy link

Hey, just a question to clarify, cause didn't find anything meaningful in docs: Can you pls list recommendations regarding best performance of this package? Cause according to profiling it takes huge amount of time to deal with mapping, so we thought maybe there are some hints we can follow to decrease this time?

For example, from what I've noticed:

  • I see that after first run it creates proxy files for the objects participating in mapping, extending them. However final classes obviously cannot be extended, that means that metadata for them will not be cached?
  • "Warm up proxies on build time from the list of classes provided by the user." - this is not implemented yet, I guess.

Generally it would be great to get some page in the docs, with a recommendations on performance or maybe things that increase/decrease performance. Thx in advance!

@priyadi
Copy link
Member

priyadi commented Sep 24, 2024

I see that after first run it creates proxy files for the objects participating in mapping, extending them. However final classes obviously cannot be extended, that means that metadata for them will not be cached?

Metadata is always cached, final or not final. Final only means the proxy will not be created.

"Warm up proxies on build time from the list of classes provided by the user." - this is not implemented yet, I guess.

Not yet implemented. But proxy and metadata generation only affects the first mapping of the pair.

Currently, the only available option to speed up things is to disable proxy (but then again proxy might speed things up depending on the use case). Further optimization needs to happen in the codebase.

If you have the profiling result, it might be very useful.

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

No branches or pull requests

2 participants