Well it doesnt seem to be as efficient as expected. Replacing a plain old
injection by an instance i expected no more than x3 in execution time but
was easily x10...and i had less than 5 beans.

Not sure what takes time...thought to cache the whole result in the
instance but if you have better ideas it is still open for 1.1.8 and 1.2.0
:)
Le 20 janv. 2013 19:24, "Arne Limburg" <[email protected]> a
écrit :

> Hi Romain,
>
> It is cached in the InjectionResolver, that should suffice.
>
>
> Cheers,
> Arne
>
> Am 19.01.13 17:44 schrieb "Romain Manni-Bucau" unter
> <[email protected]>:
>
> >Hi guys,
> >
> >is there any reason
> >why org.apache.webbeans.inject.instance.InstanceImpl#resolveBeans() is not
> >cached in the instance of InstanceImpl (whatever the cache is - a volatile
> >var, an atomicref or even a synchronized block)?
> >
> >typically doing this pattern: if (!instance.isAmbiguous()) { return
> >instance.get(); } you'll call it twice for nothing (and it can be O(n)
> >with
> >n the numbe rof beans)...or just regarding runtime it seems weird no?
> >
> >wdyt?
> >
> >*Romain Manni-Bucau*
> >*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> >*Blog:
> >**http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> >*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> >*Github: https://github.com/rmannibucau*
>
>

Reply via email to