[ https://issues.apache.org/jira/browse/OWB-1382?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17308751#comment-17308751 ]
Vladimir Dvorak commented on OWB-1382: -------------------------------------- Ok, I'm understaning and attaching some numbers from my investigation of it. Please close the issue, if you don't see it to be relevant. Thanks. In small example DS+OWB [https://github.com/skybber/pf-expensive-converter] , there is 263 beans and 2895 calls of InjectionResolver BeansDeployer.deploy() takes 1.7s, caching has no measurable influence on performance. When I've checked on my large project, there is 1690 beans and InjectionResolver is called 18244x (~1M iterations) caching shows 15-20% improvement of BeansDeployer.deploy() > Class javax.enterprise.inject.spi.BeanManager not cached on start > ----------------------------------------------------------------- > > Key: OWB-1382 > URL: https://issues.apache.org/jira/browse/OWB-1382 > Project: OpenWebBeans > Issue Type: Improvement > Components: Context and Scopes > Reporter: Vladimir Dvorak > Priority: Minor > > Class javax.enterprise.inject.spi.BeanManager generates a lot of full lookups > (tens of thousands) in InjectionResolver.implResolveByType() when OWB is > starting even in simple project. It looks that OWB starts could be improved > by 10-20% by introducing caching. I'm trying to put cache in BeanImpl as is > shown there: > > [https://github.com/skybber/pf-expensive-converter/blob/main/addhoc/org/apache/webbeans/container/InjectionResolver.java#L491] > > it skips expensive iteration over all beans and improves start of OWB, in my > case from 10.5s to 9.9s. Probably there is better way how to do it, since the > problem is only with the class javax.enterprise.inject.spi.BeanManager. > > > -- This message was sent by Atlassian Jira (v8.3.4#803005)