Hi,
On Tue, Aug 25, 2015 at 7:07 PM, Nigel Deakin <nigel.deakin(a)oracle.com> wrote:
On 25/08/2015 12:38, arjan tijms wrote:
This looks very interesting. Does this work with any normal scope?
Yes, all normal scopes that are available in standard Java EE support
this as far as I know.
There's the small caveat that CDI itself doesn't know about this
automatically for any custom normal scope. That implementation of such
scope (via a Context) must explicitly throw these events.
For example, this is what Mojarra does for the @FlowScoped implementation:
https://github.com/omnifaces/mojarra/blob/master/jsf-ri/src/main/java/com...
Which is fired when the scope starts here:
https://github.com/omnifaces/mojarra/blob/master/jsf-ri/src/main/java/com...
(the exact same code is used for @ViewScoped in Mojarra as well)
then every time a new request starts, this event is fired which
causes an
instance of the bean to be created for that request?
Yes, that is what this does ;)
Kind regards,
Arjan Tijms