Let's keep this conversation on CDI-dev list, please (adding back to CC).
Hmm, I think it is not forbidden to add another plain java annotation.
However, having it working as scope and cdi qualifier in the same time won't work.
----- Original Message -----
From: "Todor Boev" <rinsvind(a)gmail.com>
To: "Matej Novotny" <manovotn(a)redhat.com>
Sent: Friday, September 1, 2017 12:33:54 PM
Subject: Re: [cdi-dev] Attributes on scope annotations
Thank you for the timely replay,
I need portable behavior, so the other option I am considering is to
meta-annotate the scope annotation with the additional information I need.
The issues are now: is this allowed, can in principle my custom
meta-annotation be a qualifier. Probably a plain annotation will be
sufficient, but I may need to have it do double-duty as a qualifier as well.
Thanks in advance,
On Fri, Sep 1, 2017 at 11:49 AM, Matej Novotny <manovotn(a)redhat.com> wrote:
> Hello Todor,
> From CDI specification 2.0 section 2.4.2 Defining new scopes:
> "A scope type must not have any attributes. If a scope type has attributes
> non-portable behavior results."
>  http://docs.jboss.org/cdi/spec/2.0/cdi-spec.html#
> ----- Original Message -----
> > From: "Todor Boev" <rinsvind(a)gmail.com>
> > To: cdi-dev(a)lists.jboss.org
> > Sent: Friday, September 1, 2017 9:51:47 AM
> > Subject: [cdi-dev] Attributes on scope annotations
> > Hello,
> > Is it against the CDI 2.0 specification to have attributes on a scope
> > annotation? If not is this a corner case that may become forbidden or
> > not be taken into account in future versions of the specification?
> > E.g. @ComponentScoped("my-component")
> > With Weld 3.0.0 I was able to successfully use such annotations.
> > Regards,
> > Todor
> > _______________________________________________
> > cdi-dev mailing list
> > cdi-dev(a)lists.jboss.org
> > https://lists.jboss.org/mailman/listinfo/cdi-dev
> > Note that for all code provided on this list, the provider licenses the
> > under the Apache License, Version 2
> > (http://www.apache.org/licenses/LICENSE-2.0.html
). For all other ideas
> > provided on this list, the provider waives all patent and other
> > property rights inherent in such information.