[cdi-dev] Defining the order of event thru priority

Antoine Sabot-Durand antoine at sabot-durand.net
Mon Nov 28 05:43:16 EST 2016


Hi all,

In a recent discussion with Martin, I realized that the use of @Priotiy is
not consistent in CDI 1.2:

- For Interceptor and decorator the lowest value in @Priority is first (def
in interceptor spec and 8.2.1)
- For Alternatives the Highest value in @Priroty is first (def in 5.2.2)

Since we have these different interpretation of @Priority value in the spec
, we may find more consistent to change the definition of event ordering
with the @Priority annotation.
Right now we have:

"Observers with smaller priority values are called first"

We may find more intuitive to change it to:

"Observers with higher priority values are called first"

It will remove the oxymoron effect of the sentence and align this ordering
on @Alternative way of using @Priorty.

Wdyt?

Antoine
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/cdi-dev/attachments/20161128/20e86cde/attachment.html 


More information about the cdi-dev mailing list