On 03.01.2013 17:27, Jeremy Bauer wrote:
> I also do not like the idea of re-using @Singleton because it is a
> component defining annotation. If we are just talking about a single
> switch, adding an attribute to the annotation ex.
> @MessageDriven(singleton=true) is my preference.
What adding singleton=true to Stateless and turning Singleton into a
stereotype?
@Stereotype
@Stateless(singleton=true)
public @interface Singleton {
}
Cheers
Philippe