myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gerhard Petracek (JIRA)" <...@myfaces.apache.org>
Subject [jira] [Comment Edited] (MYFACES-3786) Web Container injection support should be provided for additional lifecycle artifacts (not just managed beans)
Date Tue, 08 Oct 2013 15:58:45 GMT

    [ https://issues.apache.org/jira/browse/MYFACES-3786?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13789313#comment-13789313
] 

Gerhard Petracek edited comment on MYFACES-3786 at 10/8/13 3:58 PM:
--------------------------------------------------------------------

if you would like to support it that way, you can
#1 add an own implementation of javax.enterprise.inject.spi.Bean
#2 implement #create and #destroy (in #create you build the chain you are trying to do via
std. reflection), use #inject, #postConstruct (and #preDestroy in #destroy) via javax.enterprise.inject.spi.InjectionTarget
#3 veto all other beans of the same type (to avoid issues with the default cdi rules)
#4 perform a std lookup per type and you will get the whole chain

for further details (like the correct handling of CreationalContext,...) you can have a look
at what we are doing at apache deltaspike.


was (Author: gpetracek):
if you would like to support it that way, you can
#1 add an own implementation of javax.enterprise.inject.spi.Bean
#2 implement #create and #destroy (in #create you build the chain you are trying to do via
std. reflection), use #inject, #postConstruct (and #preDestroy in #destroy) via javax.enterprise.inject.spi.InjectionTarget
#3 veto all other beans of the same type (to avoid issues with the default cdi rules)
#4 perform a std lookup per type and you will get the whole chain

for further details you can have a look at what we are doing at apache deltaspike.

> Web Container injection support should be provided for additional lifecycle artifacts
(not just managed beans)
> --------------------------------------------------------------------------------------------------------------
>
>                 Key: MYFACES-3786
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3786
>             Project: MyFaces Core
>          Issue Type: Task
>          Components: JSR-344
>            Reporter: Leonardo Uribe
>            Assignee: Leonardo Uribe
>         Attachments: cdiELResolver.patch, cdiELresolverWeb.zip, cdiELResolver.zip, cdipackage.patch,
cdiPartialViewContext.war, cdiPartialViewContext.zip, cdi.patch, cdiValidatorSource.zip, cdiValidator.war
>
>
> This issue is all about how to inject beans into jsf artifacts.
> See JSF 2.2 section 5.4.1
> The problem here is in some point we need to give the control to the underlying environment
to inject beans into the artifacts, but we don't know much about how to properly do it, so
we need to try with examples.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message