On Thu, Aug 4, 2011 at 2:03 AM, Sanne Grinovero <sanne(a)infinispan.org> wrote:
2011/8/3 Dan Berindei <dan.berindei(a)gmail.com>:
> I think it's supposed to be an automatic version of
>
https://github.com/infinispan/infinispan/blob/master/core/src/main/java/o...
> I prefer the manual version in GlobalConfiguration, although I don't
> think there are any users for those components either.
>
> Dan
I was thinking something similar, but would like to know if it's still
used, somebody must know about this code?
Initially I thought it was some clever way to extract instances from a
user-customizable configuration instance, but since it's reflecting on
the static definition of Configuration it doesn't look like it's meant
to support extensions of it.
If it's used we could cache the references to existing methods and
track also which methods don't exist, so we limit the number of
exceptions to a single one per attempted method name (i.e. starting
500 caches would cost as starting one).
Even a custom Configuration could register its objects in the
component registry manually in an @Inject method, like
GlobalConfiguration does. But I don't see any good reason for
injecting bits of the configuration instead of injecting the whole
thing and navigating the configuration tree in the component code.
So I'd go with your initial suggestion and remove it.
Dan
_______________________________________________
infinispan-dev mailing list
infinispan-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/infinispan-dev