deltaspike-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Porter <lightguard...@gmail.com>
Subject Re: [DISCUSS] [DELTASPIKE-7] ExpressionActivated
Date Tue, 03 Jan 2012 23:52:11 GMT
+1 I think that's a good way to do things. Also helps us move forward.

On Tue, Jan 3, 2012 at 16:43, John D. Ament <john.d.ament@gmail.com> wrote:

> +1 for exclude as described.
>
> On Tue, Jan 3, 2012 at 4:24 PM, Gerhard Petracek <
> gerhard.petracek@gmail.com
> > wrote:
>
> > +1
> > however, we should start a new thread to increase the visibility.
> >
> > regards,
> > gerhard
> >
> >
> >
> > 2012/1/3 Pete Muir <pmuir@redhat.com>
> >
> > > I like this :-)
> > >
> > > On 3 Jan 2012, at 19:33, Arne Limburg wrote:
> > >
> > > > @Exclude could be used in a sentence:
> > > >
> > > > @Exclude(inProjectStage=Production.class)
> > > > @Exclude(notInProjectStage=UnitTest.class)
> > > > @Exclude(onExpression="...")
> > > >
> > > > -----Urspr√ľngliche Nachricht-----
> > > > Von: Pete Muir [mailto:pmuir@redhat.com]
> > > > Gesendet: Dienstag, 3. Januar 2012 20:26
> > > > An: deltaspike-dev@incubator.apache.org; Mark Struberg
> > > > Betreff: Re: [DISCUSS] [DELTASPIKE-7] ExpressionActivated
> > > >
> > > > I like this idea, but we are straying from the "guidelines" that the
> > > spec has laid down for naming - that in general "provided" annotations
> > > don't have members, and that the annotation should basically make sense
> > in
> > > a sentence.
> > > >
> > > > If we can rectify this, but keep the idea, I'm +1. Unfortunately, I'm
> > > out of ideas on how achieve this ;-) I will try to mull it over
> tonight.
> > > >
> > > > On 3 Jan 2012, at 17:19, Mark Struberg wrote:
> > > >
> > > >> Sitting together with Gerhard we had another idea.
> > > >>
> > > >> What do you think about unifying all this stuff
> > > >>
> > > >>
> > > >> @Veto
> > > >>
> > > >> @Veto(projectStage=UnitTest.class)
> > > >>
> > > >> @Veto(notInProjectStage=Production.class)
> > > >>
> > > >> @Veto(expression="myproperty=myValue")
> > > >>
> > > >>
> > > >> (independent on the final name of @Veto)
> > > >>
> > > >>
> > > >>
> > > >> Instead of having projectStage and notInProjectStage as explicit
> > > >> annotation values, we could also move this to a string based
> > > >> expression For example
> > > >> @Veto("projectStage=Production")
> > > >> The downside is that we would loose the type safety, thus I don't
> > > really like it.
> > > >>
> > > >> WDYT?
> > > >>
> > > >> LieGrue,
> > > >> strub + os890
> > > >>
> > > >>
> > > >>
> > > >>
> > > >> ----- Original Message -----
> > > >>> From: Mark Struberg <struberg@yahoo.de>
> > > >>> To: "deltaspike-dev@incubator.apache.org"
> > > >>> <deltaspike-dev@incubator.apache.org>
> > > >>> Cc:
> > > >>> Sent: Tuesday, January 3, 2012 2:48 PM
> > > >>> Subject: Re: [DISCUSS] [DELTASPIKE-7] ExpressionActivated
> > > >>>
> > > >>> Back then we also had a few discussions about this very topic.
> > > >>>
> > > >>>
> > > >>> We did choose @ProjectStageActivated and @ExpressionActivated,
> > > >>> because the beans are not 'actived by this expression' but 'only
> > > >>> active on this expression'
> > > >>>
> > > >>> Any @Alternative @ActivatedByExtression public class MyBean will
> > > >>> _not_ get automatically enabled, but _still_ needs the
> <alternatives>
> > > >>> entry in beans.xml!
> > > >>>
> > > >>> @ActivatedByExpression and @ActivatedByProjectStage (or the
> > > >>> equivalent ..On...) imo implies a bit too much.
> > > >>>
> > > >>> Actually it's rather the other way around. A bean will _not_ get
> > > >>> _vetoed_ if the underlying expression resolves to 'true' ;)
> > > >>>
> > > >>> So I'm +0.8 for @ExpressionActivated and -0.2 against
> > > >>> @ActivatedByExpression. Imo the @ActivatedOnExpression is a bit
> > > >>> better, so +0.2 for it.
> > > >>>
> > > >>> LieGrue,
> > > >>> strub
> > > >>>
> > > >>>
> > > >>>
> > > >>> ----- Original Message -----
> > > >>>> From: Peter Muir <pmuir@redhat.com>
> > > >>>> To: "deltaspike-dev@incubator.apache.org"
> > > >>> <deltaspike-dev@incubator.apache.org>
> > > >>>> Cc: "deltaspike-dev@incubator.apache.org"
> > > >>> <deltaspike-dev@incubator.apache.org>
> > > >>>> Sent: Tuesday, January 3, 2012 2:18 PM
> > > >>>> Subject: Re: [DISCUSS] [DELTASPIKE-7] ExpressionActivated
> > > >>>>
> > > >>>> I would prefer @activatedonexpression, it fits better with
the
> spec.
> > > >>>>
> > > >>>> As an alternative, what about @ActivatedByExpression which
to me
> > > >>>> reads
> > > >>> better.
> > > >>>>
> > > >>>>
> > > >>>> --
> > > >>>> Pete Muir
> > > >>>> http://in.relation.to/Bloggers/Pete
> > > >>>>
> > > >>>> On 2 Jan 2012, at 05:34, Jason Porter <lightguard.jp@gmail.com>
> > > >>> wrote:
> > > >>>>
> > > >>>>>  +1 for @ActivatedOnExpression. It reads better which
goes a long
> > > >>>>> way
> > > >>> for
> > > >>>> easy to use, self documenting code.
> > > >>>>>
> > > >>>>>  Sent from my iPhone
> > > >>>>>
> > > >>>>>  On Jan 1, 2012, at 17:57, Gerhard Petracek
> > > >>>> <gerhard.petracek@gmail.com> wrote:
> > > >>>>>
> > > >>>>>>  hi,
> > > >>>>>>
> > > >>>>>>  please send your opinion about the name (@ActivatedOnExpression
> > vs
> > > >>>>>>  @ExpressionActivated).
> > > >>>>>>
> > > >>>>>>  thx & regards,
> > > >>>>>>  gerhard
> > > >>>>>>
> > > >>>>>>
> > > >>>>>>
> > > >>>>>>  2011/12/20 Christian Kaltepoth <christian@kaltepoth.de>
> > > >>>>>>
> > > >>>>>>>  +1
> > > >>>>>>>
> > > >>>>>>>  2011/12/20 Marius Bogoevici
> > > >>> <marius.bogoevici@gmail.com>:
> > > >>>>>>>>  +1
> > > >>>>>>>>
> > > >>>>>>>>  On 2011-12-19, at 8:28 AM, Gerhard Petracek
wrote:
> > > >>>>>>>>
> > > >>>>>>>>>  hi @ all,
> > > >>>>>>>>>
> > > >>>>>>>>>  fyi: please check [1] before you answer.
> > > >>>>>>>>>
> > > >>>>>>>>>  [2] provides a short introduction as
well as the basic
> > > >>>
> > > >>>> usage.
> > > >>>>>>>>>
> > > >>>>>>>>>  the basic concept:
> > > >>>>>>>>>  via the annotation @ExpressionActivated
it's
> > > >>> possible
> > > >>>> to veto bean
> > > >>>>>>>>>  implementations based on the given expression.
> > > >>>>>>>>>  it's possible to change the supported
syntax via
> > > >>> an
> > > >>>> optional
> > > >>>>>>>>>  ExpressionInterpreter.
> > > >>>>>>>>>
> > > >>>>>>>>>  please send
> > > >>>>>>>>>  +1, +0 or -1 because...
> > > >>>>>>>>>  for the basic idea as well as the basic
concept.
> > > >>>>>>>>>  if there are >basic< objections,
please also add
> > > >>> them
> > > >>>> to [3]
> > > >>>>>>>>>
> > > >>>>>>>>>  regards,
> > > >>>>>>>>>  gerhard
> > > >>>>>>>>>
> > > >>>>>>>>>  [1] http://markmail.org/message/7yefspfuvtz4jvmp
> > > >>>>>>>>>  [2]
> > > >>>>>>>>>
> > > >>>>>>>
> > > >>>>
> > > >>>
> > https://cwiki.apache.org/confluence/display/EXTCDI/Core+Usage#CoreUsa
> > > >>> ge-@ExpressionActivated
> > > >>>>>>>>>  [3]
> > > >>>>>>>>>
> > > >>>>>>>
> > > >>>>
> > https://cwiki.apache.org/confluence/display/DeltaSpike/SE+Feature+Ra
> > > >>>> nking
> > > >>>>>>>>
> > > >>>>>>>
> > > >>>>>>>
> > > >>>>>>>
> > > >>>>>>>  --
> > > >>>>>>>  Christian Kaltepoth
> > > >>>>>>>  Blog: http://chkal.blogspot.com/
> > > >>>>>>>  Twitter: http://twitter.com/chkal
> > > >>>>>>>
> > > >>>>
> > > >>>
> > > >
> > >
> > >
> >
>



-- 
Jason Porter
http://lightguard-jp.blogspot.com
http://twitter.com/lightguardjp

Software Engineer
Open Source Advocate
Author of Seam Catch - Next Generation Java Exception Handling

PGP key id: 926CCFF5
PGP key available at: keyserver.net, pgp.mit.edu

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message