users@hk2.java.net

Custom injection resolver non Singleton

From: Trenton D. Adams <trenton.d.adams_at_gmail.com>
Date: Wed, 20 Apr 2016 17:30:34 -0600

According to the documentation, custom injection resolvers do not need to
be of the Singleton scope. But there's code in HK2 that forces them to be
in that scope. Is this a design problem, or a documentation problem?

https://hk2.java.net/custom-resolver-example.html

It says...
The AlternateInjectResolver is in the @Singleton context, which is the
usual context for implementations of InjectionResolver
<https://hk2.java.net/apidocs/org/glassfish/hk2/api/InjectionResolver.html>.
In general however implementations of InjectionResolver
<https://hk2.java.net/apidocs/org/glassfish/hk2/api/InjectionResolver.html> may
be in any context.