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
com.mycila.inject.internal.Reflect may block threads #6
Comments
|
Do you have a junit test I could use to reproduce and verify the correction ? |
|
Hi, I've juste read again: you are using a quite out-dated version of mycila guice. See http://code.mycila.com/guice/ The new version has several module and does not seem to have this performance issue since there is no call to getDeclaredAnnotations(). |
|
Correction: it has the bug also., I am fixing it ;-) |
|
fixed in 3.4.ga |
|
Hello Mr.Carbou, Von: Mathieu Carbou [mailto:notifications@github.com] — |
|
Yes definitely. Actually this is caused also by calls to isAnnotationPresent, which I use. So if you are not using eagerly loaded singletons with guice, annotaton parsing is done at every new binding for JSR250. |
|
You can downlaod an updated 2.10 version with a guava cache here: http://dl.bintray.com/mathieucarbou/public/ |
|
Thanks a lot. Von: Mathieu Carbou [mailto:notifications@github.com] You can downlaod an updated 2.10 version with a guava cache here: http://dl.bintray.com/mathieucarbou/public/ — |
We are using mycila-guice 2.10 GA.
We found out that many threads are blocked due to a call on „java.lang.reflect.Method#declaredAnnotations()“ by „com.mycila.inject.internal.Reflect#apply(AnnotatedElement)“. Please have a look at the attached screenshot.
„java.lang.reflect.Method#declaredAnnotations()“ is synchronized, and thus many threads are blocked for a few seconds.
The text was updated successfully, but these errors were encountered: