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

Add an option for caching the results of Class.forName in DefaultCreator #789

Closed
rlodge opened this issue May 29, 2015 · 4 comments
Closed
Milestone

Comments

@rlodge
Copy link
Contributor

rlodge commented May 29, 2015

During performance testing we discovered that calls to Class.forName were taking a large amount of time relative to our expectations. We'd like to have an option for caching the results of the class name lookup so that the forName method is only called on new classes.

@evanchooly
Copy link
Member

That happens in a number of places in Morphia. Any particular hotspot giving you problems?

@rlodge
Copy link
Contributor Author

rlodge commented May 29, 2015

DefaultCreator. We've made a change and seen a 10-12% performance improvement, at least in our case. I'm preparing a pull request.

@evanchooly
Copy link
Member

excellent. I look forward to seeing it. it won't make the 1.0 cut but we can do a 1.0.1 release soon enough.

@rlodge rlodge mentioned this issue May 29, 2015
@evanchooly evanchooly added this to the 1.1.0 milestone May 29, 2015
@rlodge
Copy link
Contributor Author

rlodge commented May 29, 2015

Works for me, as long as it's on the roadmap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants