You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by David Blevins <da...@visi.com> on 2009/08/19 23:55:08 UTC

Webapp Annotation processing for 299

I've been talking with Gurkan of OpenWebBeans over on the OpenEJB list  
and it seemed like a good idea to kick the thread over here as well.

The long and short of it is that we'll need to scan 299 managed beans  
at deploy time exactly as we do for JSF.

Wanted to point him at the JSF scanning code, but can't remember the  
details.  Anyone remember?  An svn link is fine.


-David




Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
>>>Quick correction, rar modules are not eligible as far as I know.
But it is defined in the specification.

>From the specification, defined in Chapter - 12.1 Bean Deployment Archives

> In an application deployed as an ear, the container searches every bean
> deployment archive belonging to the ear. The bean deployment archive may be
> library jars, ejb jars, rars or WEB-INF/classes" directory.
>

Thanks;

--Gurkan

2009/8/25 David Blevins <da...@visi.com>

> Quick correction, rar modules are not eligible as far as I know.
>
> Basically, anywhere you can use a persistence.xml you can have a beans.xml.
>
> -David
>
>
> On Aug 23, 2009, at 11:00 PM, Gurkan Erdogdu wrote:
>
>  Thanks a lot david jencks. Actually, webbeans can be included in any
>> ejb,war,ear,rar and library modules. But it is a good start with web
>> builders. Let's see how it works.
>>
>> --Gurkan
>>
>> 2009/8/23 David Jencks <da...@yahoo.com>
>> Hi Gurkan,
>>
>> to get a ModuleBuilderExtension to do anything it has to be associated
>> with a ModuleBuilder for a type of ee app which will call it at the
>> appropriate points during deployment.  I'm not sure what kinds of ee modules
>> web beans can included in, but I added the OWBMBE to the jetty7 and tomcat6
>> builders in rev 806989.  If this is not quite right you should be able to
>> figure out what to do with other module builders.
>>
>> hope this is in the right direction :-)
>>
>> thanks
>> david jencks
>>
>> On Aug 23, 2009, at 5:32 AM, Gurkan Erdogdu wrote:
>>
>>  Hi David;
>>>
>>> I have deployed plugins(2 car ) into the server. Server calls
>>> OpenWebBeansModuleBuilderExtension while it starts. But it never calls
>>> "createModule, addGBeans" methods. Do I have to configure something for
>>> this?
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/22 Gurkan Erdogdu <cg...@gmail.com>
>>> Great help David!
>>>
>>> Thanks a lot. I will try to fill the blanks.
>>>
>>> --Gurkan
>>>
>>> 2009/8/22 David Blevins <da...@visi.com>
>>>
>>> Great summary, thanks!
>>>
>>> So as I mentioned on the OpenEJB list and the reason I kicked the thread
>>> over here is that the ServletContextListener approach to scanning doesn't
>>> work as none of those things exist at deploy time.
>>>
>>> To try and move things forward I've created a basic plugin for
>>> OpenWebBeans that can serve as a starting point for the integration.  This
>>> will help get us out of the abstract and right down to the nuts and bolts.
>>>
>>> DEPLOYMENT
>>>
>>> Long story short, the code that scans the managed bean classes for
>>> @Resource etc. goes here:
>>>
>>>
>>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>>>
>>> The code to do the @Resource scanning is actually in there already, it's
>>> the line like this:
>>>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,
>>> buildingContext);
>>> What needs to happen in this class is we need to get a complete list of
>>> the managed bean classes so they can be scanned by the Geronimo naming
>>> builder.  This class is an extension to the Geronimo deployment system, so
>>> no webapp objects exist yet.  I know that the OpenWebBeans code doesn't
>>> currently work like this and relies on ServetContext and other things.  We
>>> will have to find a way to get that to work without the use of any servet
>>> APIs.
>>>
>>> A bonus is that you can install any servlets or filters or listeners you
>>> like into the webapp so when it boots, anything you'd like to add will be
>>> there without the user having to add it.  A pretty cool advantage to being
>>> part of the deployment system.  I've got some code in there that adds a
>>> ServletContextListener -- I left the classname of the listener blank, you
>>> just need to fill it in.
>>>
>>> For a great example of what the JSF deployer extension looks like, see
>>> this class:
>>>
>>>
>>>
>>> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>>>
>>>
>>> RUNTIME
>>>
>>> Here's where you can add any startup and shutdown code you'd like:
>>>
>>>
>>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>>>
>>> This will be guaranteed to run just before the webapp starts up and stop
>>> just after the webapp stops.  Great place for initialization code and taking
>>> care of getting any hooks into Geronimo that you might need/want for while
>>> the webapp is running.
>>>
>>> This doesn't tackle everything on the TODO list but is a step in the
>>> right direction.
>>>
>>> -David
>>>
>>>
>>> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>>>
>>> I want to give brief introduction about current implementation in the
>>> view of integration points
>>>
>>> Brief Summary About Current Situation
>>> ---------------------------------------------------------
>>> Currently we bootstrap OpenWebBeans via ServletContextListener. It
>>> supports following containers
>>>
>>> - Java Web Containers like Jetty, Tomcat etc.
>>> - Tomcat Embeddable OpenEJB Container
>>>
>>> If developer wants to use OWB functionality in his application, it has to
>>> configure its "web.xml" to include some OWB specific classes. For EJB
>>> functionality, we use embeddable Tomcat OpenEJB container. To use EJB
>>> functionality, developer must annotate their EJB classes with OWB specific
>>> "Interceptor" class.
>>>
>>> How OWB Boots Currently(From integration point of view)
>>> -------------------------------------------------------
>>> 1* Web Container calls OWB specific context listener's "application
>>> started" method
>>> 2* OWB container scans related classes from the artifacts (if
>>> META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
>>> deployment)
>>> 3* If developer configures OWB to use EJB functionality, for each scanned
>>> class, it asks OpenEJB to learn whether it is an EJB class or not (Using EJB
>>> Plugin that is written accroding to the OpenEJB)
>>> 4* If it is an EJB class, it creates EJB bean and register it with the
>>> OWB container otherwise if it is a Java EE defined Managed Bean Class, it
>>> creates a "Managed Bean" and register it with the OWB container.
>>>
>>> Developer Responsibility to Use OWB
>>> --------------------------------------------------------
>>> 1* Add servlet context listener to his web module's "web.xml"
>>> 2* Annotate EJB classes with OWB interceptor
>>> 3* Configure OWB container to use EJB functionality
>>> 4* Configure some OWB specific parameters (For example : if use JMS
>>> injections, specify ConnectionFactory JNDI name)
>>>
>>> Current Problems
>>> -----------------------------------------------------
>>> 1* Currently we just support "WAR" module with embeddable EJB.
>>> 2* Developer requires to update WAR/EJB module metadata files to use OWB.
>>> 3* Standalone EJB JAR,RAR, EAR not supported
>>> 4* Injections into "Managed Beans" class not well supported. (For example
>>> : @Resource, @WebServiceRef, @EJB, @PersistenceUnit,@PersistenceContext.)
>>>
>>> How Could We Integrate with Geronimo
>>> ---------------------------------------------------------
>>> 1* Geronimo looks for deployment. If it contains "beans.xml", it
>>> automatically registers OWB servlet context listener with WAR's web.xml at
>>> deployment time
>>> 2* Automatically registers OWB EJB interceptor with EJBs at deployment
>>> time (If module is EJB module or EAR module containing EJB modules)
>>> 3* Support EJB JAR, EAR, RAR modules
>>> 4* Write EJB Plugin for Geronimo
>>> 5* Supports injections for Managed Beans
>>>
>>> I hope this helps a bit more
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>>> Gurkan Erdogdu wrote:
>>> >>>We'd be interested in any details about what integration work might be
>>> needed to add this to Geronimo.
>>> It is a really fascinating thing that you support us to finish
>>> implementation and pass TCK :) We really need a help.
>>> I think there is a great willingness to help you with this, but I was
>>> looking form something more specific, such as the actual areas/functions
>>> where integration assistance is needed.
>>> Rick
>>>
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>>
>>>
>>>  Gurkan Erdogdu wrote:
>>>
>>>      Hi;
>>>
>>>      Thanks for kicking discussion David.
>>>
>>>      As you may already know Java EE 6 will be planned to release
>>>      on  November. Do you have any plan or roadmap  to integrate
>>>      JSR-299 with Geronimo?
>>>
>>>  We have a tentative roadmap for implementing the Web Profile at:
>>>
>>>
>>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>>
>>>  For the JEE6 plans, the web profile did not include JSR 299, which
>>>  I guess has changed recently.  We'd be interested in any details
>>>  about what integration work might be needed to add this to Geronimo.
>>>  Rick
>>>
>>>
>>>      We are working hard to implement full specification but it has
>>>      some parts that requires to integrate with Java EE server tightly.
>>>
>>>      Thanks;
>>>
>>>      --Gurkan
>>>
>>>      2009/8/20 David Blevins <david.blevins@visi.com
>>>      <ma...@visi.com> <mailto:david.blevins@visi.com
>>>
>>>      <ma...@visi.com>>>
>>>
>>>
>>>         I've been talking with Gurkan of OpenWebBeans over on the
>>>      OpenEJB
>>>         list and it seemed like a good idea to kick the thread over
>>>      here
>>>         as well.
>>>
>>>         The long and short of it is that we'll need to scan 299 managed
>>>         beans at deploy time exactly as we do for JSF.
>>>
>>>         Wanted to point him at the JSF scanning code, but can't
>>>      remember
>>>         the details.  Anyone remember?  An svn link is fine.
>>>
>>>
>>>         -David
>>>
>>>
>>>
>>>
>>>
>>>
>>>      --        Gurkan Erdogdu
>>>      http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>
>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by David Blevins <da...@visi.com>.
Quick correction, rar modules are not eligible as far as I know.

Basically, anywhere you can use a persistence.xml you can have a  
beans.xml.

-David

On Aug 23, 2009, at 11:00 PM, Gurkan Erdogdu wrote:

> Thanks a lot david jencks. Actually, webbeans can be included in any  
> ejb,war,ear,rar and library modules. But it is a good start with web  
> builders. Let's see how it works.
>
> --Gurkan
>
> 2009/8/23 David Jencks <da...@yahoo.com>
> Hi Gurkan,
>
> to get a ModuleBuilderExtension to do anything it has to be  
> associated with a ModuleBuilder for a type of ee app which will call  
> it at the appropriate points during deployment.  I'm not sure what  
> kinds of ee modules web beans can included in, but I added the  
> OWBMBE to the jetty7 and tomcat6 builders in rev 806989.  If this is  
> not quite right you should be able to figure out what to do with  
> other module builders.
>
> hope this is in the right direction :-)
>
> thanks
> david jencks
>
> On Aug 23, 2009, at 5:32 AM, Gurkan Erdogdu wrote:
>
>> Hi David;
>>
>> I have deployed plugins(2 car ) into the server. Server calls  
>> OpenWebBeansModuleBuilderExtension while it starts. But it never  
>> calls "createModule, addGBeans" methods. Do I have to configure  
>> something for this?
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/22 Gurkan Erdogdu <cg...@gmail.com>
>> Great help David!
>>
>> Thanks a lot. I will try to fill the blanks.
>>
>> --Gurkan
>>
>> 2009/8/22 David Blevins <da...@visi.com>
>>
>> Great summary, thanks!
>>
>> So as I mentioned on the OpenEJB list and the reason I kicked the  
>> thread over here is that the ServletContextListener approach to  
>> scanning doesn't work as none of those things exist at deploy time.
>>
>> To try and move things forward I've created a basic plugin for  
>> OpenWebBeans that can serve as a starting point for the  
>> integration.  This will help get us out of the abstract and right  
>> down to the nuts and bolts.
>>
>> DEPLOYMENT
>>
>> Long story short, the code that scans the managed bean classes for  
>> @Resource etc. goes here:
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>>
>> The code to do the @Resource scanning is actually in there already,  
>> it's the line like this:
>>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,  
>> buildingContext);
>> What needs to happen in this class is we need to get a complete  
>> list of the managed bean classes so they can be scanned by the  
>> Geronimo naming builder.  This class is an extension to the  
>> Geronimo deployment system, so no webapp objects exist yet.  I know  
>> that the OpenWebBeans code doesn't currently work like this and  
>> relies on ServetContext and other things.  We will have to find a  
>> way to get that to work without the use of any servet APIs.
>>
>> A bonus is that you can install any servlets or filters or  
>> listeners you like into the webapp so when it boots, anything you'd  
>> like to add will be there without the user having to add it.  A  
>> pretty cool advantage to being part of the deployment system.  I've  
>> got some code in there that adds a ServletContextListener -- I left  
>> the classname of the listener blank, you just need to fill it in.
>>
>> For a great example of what the JSF deployer extension looks like,  
>> see this class:
>>
>>
>> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>>
>>
>> RUNTIME
>>
>> Here's where you can add any startup and shutdown code you'd like:
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>>
>> This will be guaranteed to run just before the webapp starts up and  
>> stop just after the webapp stops.  Great place for initialization  
>> code and taking care of getting any hooks into Geronimo that you  
>> might need/want for while the webapp is running.
>>
>> This doesn't tackle everything on the TODO list but is a step in  
>> the right direction.
>>
>> -David
>>
>>
>> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>>
>> I want to give brief introduction about current implementation in  
>> the view of integration points
>>
>> Brief Summary About Current Situation
>> ---------------------------------------------------------
>> Currently we bootstrap OpenWebBeans via ServletContextListener. It  
>> supports following containers
>>
>> - Java Web Containers like Jetty, Tomcat etc.
>> - Tomcat Embeddable OpenEJB Container
>>
>> If developer wants to use OWB functionality in his application, it  
>> has to configure its "web.xml" to include some OWB specific  
>> classes. For EJB functionality, we use embeddable Tomcat OpenEJB  
>> container. To use EJB functionality, developer must annotate their  
>> EJB classes with OWB specific "Interceptor" class.
>>
>> How OWB Boots Currently(From integration point of view)
>> -------------------------------------------------------
>> 1* Web Container calls OWB specific context listener's "application  
>> started" method
>> 2* OWB container scans related classes from the artifacts (if META- 
>> INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker  
>> for deployment)
>> 3* If developer configures OWB to use EJB functionality, for each  
>> scanned class, it asks OpenEJB to learn whether it is an EJB class  
>> or not (Using EJB Plugin that is written accroding to the OpenEJB)
>> 4* If it is an EJB class, it creates EJB bean and register it with  
>> the OWB container otherwise if it is a Java EE defined Managed Bean  
>> Class, it creates a "Managed Bean" and register it with the OWB  
>> container.
>>
>> Developer Responsibility to Use OWB
>> --------------------------------------------------------
>> 1* Add servlet context listener to his web module's "web.xml"
>> 2* Annotate EJB classes with OWB interceptor
>> 3* Configure OWB container to use EJB functionality
>> 4* Configure some OWB specific parameters (For example : if use JMS  
>> injections, specify ConnectionFactory JNDI name)
>>
>> Current Problems
>> -----------------------------------------------------
>> 1* Currently we just support "WAR" module with embeddable EJB.
>> 2* Developer requires to update WAR/EJB module metadata files to  
>> use OWB.
>> 3* Standalone EJB JAR,RAR, EAR not supported
>> 4* Injections into "Managed Beans" class not well supported. (For  
>> example : @Resource, @WebServiceRef, @EJB,  
>> @PersistenceUnit,@PersistenceContext.)
>>
>> How Could We Integrate with Geronimo
>> ---------------------------------------------------------
>> 1* Geronimo looks for deployment. If it contains "beans.xml", it  
>> automatically registers OWB servlet context listener with WAR's  
>> web.xml at deployment time
>> 2* Automatically registers OWB EJB interceptor with EJBs at  
>> deployment time (If module is EJB module or EAR module containing  
>> EJB modules)
>> 3* Support EJB JAR, EAR, RAR modules
>> 4* Write EJB Plugin for Geronimo
>> 5* Supports injections for Managed Beans
>>
>> I hope this helps a bit more
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>> Gurkan Erdogdu wrote:
>> >>>We'd be interested in any details about what integration work  
>> might be needed to add this to Geronimo.
>> It is a really fascinating thing that you support us to finish  
>> implementation and pass TCK :) We really need a help.
>> I think there is a great willingness to help you with this, but I  
>> was looking form something more specific, such as the actual areas/ 
>> functions where integration assistance is needed.
>> Rick
>>
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>
>>
>>   Gurkan Erdogdu wrote:
>>
>>       Hi;
>>
>>       Thanks for kicking discussion David.
>>
>>       As you may already know Java EE 6 will be planned to release
>>       on  November. Do you have any plan or roadmap  to integrate
>>       JSR-299 with Geronimo?
>>
>>   We have a tentative roadmap for implementing the Web Profile at:
>>
>>   http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>
>>   For the JEE6 plans, the web profile did not include JSR 299, which
>>   I guess has changed recently.  We'd be interested in any details
>>   about what integration work might be needed to add this to  
>> Geronimo.
>>   Rick
>>
>>
>>       We are working hard to implement full specification but it has
>>       some parts that requires to integrate with Java EE server  
>> tightly.
>>
>>       Thanks;
>>
>>       --Gurkan
>>
>>       2009/8/20 David Blevins <david.blevins@visi.com
>>       <ma...@visi.com> <mailto:david.blevins@visi.com
>>
>>       <ma...@visi.com>>>
>>
>>
>>          I've been talking with Gurkan of OpenWebBeans over on the
>>       OpenEJB
>>          list and it seemed like a good idea to kick the thread over
>>       here
>>          as well.
>>
>>          The long and short of it is that we'll need to scan 299  
>> managed
>>          beans at deploy time exactly as we do for JSF.
>>
>>          Wanted to point him at the JSF scanning code, but can't
>>       remember
>>          the details.  Anyone remember?  An svn link is fine.
>>
>>
>>          -David
>>
>>
>>
>>
>>
>>
>>       --        Gurkan Erdogdu
>>       http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com


Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
Thanks a lot david jencks. Actually, webbeans can be included in any
ejb,war,ear,rar and library modules. But it is a good start with web
builders. Let's see how it works.

--Gurkan

2009/8/23 David Jencks <da...@yahoo.com>

> Hi Gurkan,
> to get a ModuleBuilderExtension to do anything it has to be associated with
> a ModuleBuilder for a type of ee app which will call it at the appropriate
> points during deployment.  I'm not sure what kinds of ee modules web beans
> can included in, but I added the OWBMBE to the jetty7 and tomcat6 builders
> in rev 806989.  If this is not quite right you should be able to figure out
> what to do with other module builders.
>
> hope this is in the right direction :-)
>
> thanks
> david jencks
>
> On Aug 23, 2009, at 5:32 AM, Gurkan Erdogdu wrote:
>
> Hi David;
>
> I have deployed plugins(2 car ) into the server. Server calls
> OpenWebBeansModuleBuilderExtension while it starts. But it never calls
> "createModule, addGBeans" methods. Do I have to configure something for
> this?
>
> Thanks;
>
> --Gurkan
>
> 2009/8/22 Gurkan Erdogdu <cg...@gmail.com>
>
>> Great help David!
>>
>> Thanks a lot. I will try to fill the blanks.
>>
>> --Gurkan
>>
>> 2009/8/22 David Blevins <da...@visi.com>
>>
>> Great summary, thanks!
>>>
>>> So as I mentioned on the OpenEJB list and the reason I kicked the thread
>>> over here is that the ServletContextListener approach to scanning doesn't
>>> work as none of those things exist at deploy time.
>>>
>>> To try and move things forward I've created a basic plugin for
>>> OpenWebBeans that can serve as a starting point for the integration.  This
>>> will help get us out of the abstract and right down to the nuts and bolts.
>>>
>>> DEPLOYMENT
>>>
>>> Long story short, the code that scans the managed bean classes for
>>> @Resource etc. goes here:
>>>
>>>
>>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>>>
>>> The code to do the @Resource scanning is actually in there already, it's
>>> the line like this:
>>>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,
>>> buildingContext);
>>> What needs to happen in this class is we need to get a complete list of
>>> the managed bean classes so they can be scanned by the Geronimo naming
>>> builder.  This class is an extension to the Geronimo deployment system, so
>>> no webapp objects exist yet.  I know that the OpenWebBeans code doesn't
>>> currently work like this and relies on ServetContext and other things.  We
>>> will have to find a way to get that to work without the use of any servet
>>> APIs.
>>>
>>> A bonus is that you can install any servlets or filters or listeners you
>>> like into the webapp so when it boots, anything you'd like to add will be
>>> there without the user having to add it.  A pretty cool advantage to being
>>> part of the deployment system.  I've got some code in there that adds a
>>> ServletContextListener -- I left the classname of the listener blank, you
>>> just need to fill it in.
>>>
>>> For a great example of what the JSF deployer extension looks like, see
>>> this class:
>>>
>>>
>>> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>>>
>>>
>>> RUNTIME
>>>
>>> Here's where you can add any startup and shutdown code you'd like:
>>>
>>>
>>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>>>
>>> This will be guaranteed to run just before the webapp starts up and stop
>>> just after the webapp stops.  Great place for initialization code and taking
>>> care of getting any hooks into Geronimo that you might need/want for while
>>> the webapp is running.
>>>
>>> This doesn't tackle everything on the TODO list but is a step in the
>>> right direction.
>>>
>>> -David
>>>
>>>
>>> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>>>
>>>  I want to give brief introduction about current implementation in the
>>>> view of integration points
>>>>
>>>> Brief Summary About Current Situation
>>>> ---------------------------------------------------------
>>>> Currently we bootstrap OpenWebBeans via ServletContextListener. It
>>>> supports following containers
>>>>
>>>> - Java Web Containers like Jetty, Tomcat etc.
>>>> - Tomcat Embeddable OpenEJB Container
>>>>
>>>> If developer wants to use OWB functionality in his application, it has
>>>> to configure its "web.xml" to include some OWB specific classes. For EJB
>>>> functionality, we use embeddable Tomcat OpenEJB container. To use EJB
>>>> functionality, developer must annotate their EJB classes with OWB specific
>>>> "Interceptor" class.
>>>>
>>>> How OWB Boots Currently(From integration point of view)
>>>> -------------------------------------------------------
>>>> 1* Web Container calls OWB specific context listener's "application
>>>> started" method
>>>> 2* OWB container scans related classes from the artifacts (if
>>>> META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
>>>> deployment)
>>>> 3* If developer configures OWB to use EJB functionality, for each
>>>> scanned class, it asks OpenEJB to learn whether it is an EJB class or not
>>>> (Using EJB Plugin that is written accroding to the OpenEJB)
>>>> 4* If it is an EJB class, it creates EJB bean and register it with the
>>>> OWB container otherwise if it is a Java EE defined Managed Bean Class, it
>>>> creates a "Managed Bean" and register it with the OWB container.
>>>>
>>>> Developer Responsibility to Use OWB
>>>> --------------------------------------------------------
>>>> 1* Add servlet context listener to his web module's "web.xml"
>>>> 2* Annotate EJB classes with OWB interceptor
>>>> 3* Configure OWB container to use EJB functionality
>>>> 4* Configure some OWB specific parameters (For example : if use JMS
>>>> injections, specify ConnectionFactory JNDI name)
>>>>
>>>> Current Problems
>>>> -----------------------------------------------------
>>>> 1* Currently we just support "WAR" module with embeddable EJB.
>>>> 2* Developer requires to update WAR/EJB module metadata files to use
>>>> OWB.
>>>> 3* Standalone EJB JAR,RAR, EAR not supported
>>>> 4* Injections into "Managed Beans" class not well supported. (For
>>>> example : @Resource, @WebServiceRef, @EJB,
>>>> @PersistenceUnit,@PersistenceContext.)
>>>>
>>>> How Could We Integrate with Geronimo
>>>> ---------------------------------------------------------
>>>> 1* Geronimo looks for deployment. If it contains "beans.xml", it
>>>> automatically registers OWB servlet context listener with WAR's web.xml at
>>>> deployment time
>>>> 2* Automatically registers OWB EJB interceptor with EJBs at deployment
>>>> time (If module is EJB module or EAR module containing EJB modules)
>>>> 3* Support EJB JAR, EAR, RAR modules
>>>> 4* Write EJB Plugin for Geronimo
>>>> 5* Supports injections for Managed Beans
>>>>
>>>> I hope this helps a bit more
>>>>
>>>> Thanks;
>>>>
>>>> --Gurkan
>>>>
>>>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>>>> Gurkan Erdogdu wrote:
>>>> >>>We'd be interested in any details about what integration work might
>>>> be needed to add this to Geronimo.
>>>> It is a really fascinating thing that you support us to finish
>>>> implementation and pass TCK :) We really need a help.
>>>> I think there is a great willingness to help you with this, but I was
>>>> looking form something more specific, such as the actual areas/functions
>>>> where integration assistance is needed.
>>>> Rick
>>>>
>>>>
>>>> Thanks;
>>>>
>>>> --Gurkan
>>>>
>>>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>>>
>>>>
>>>>   Gurkan Erdogdu wrote:
>>>>
>>>>       Hi;
>>>>
>>>>       Thanks for kicking discussion David.
>>>>
>>>>       As you may already know Java EE 6 will be planned to release
>>>>       on  November. Do you have any plan or roadmap  to integrate
>>>>       JSR-299 with Geronimo?
>>>>
>>>>   We have a tentative roadmap for implementing the Web Profile at:
>>>>
>>>>
>>>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>>>
>>>>   For the JEE6 plans, the web profile did not include JSR 299, which
>>>>   I guess has changed recently.  We'd be interested in any details
>>>>   about what integration work might be needed to add this to Geronimo.
>>>>   Rick
>>>>
>>>>
>>>>       We are working hard to implement full specification but it has
>>>>       some parts that requires to integrate with Java EE server tightly.
>>>>
>>>>       Thanks;
>>>>
>>>>       --Gurkan
>>>>
>>>>       2009/8/20 David Blevins <david.blevins@visi.com
>>>>       <ma...@visi.com> <mailto:david.blevins@visi.com
>>>>
>>>>       <ma...@visi.com>>>
>>>>
>>>>
>>>>          I've been talking with Gurkan of OpenWebBeans over on the
>>>>       OpenEJB
>>>>          list and it seemed like a good idea to kick the thread over
>>>>       here
>>>>          as well.
>>>>
>>>>          The long and short of it is that we'll need to scan 299 managed
>>>>          beans at deploy time exactly as we do for JSF.
>>>>
>>>>          Wanted to point him at the JSF scanning code, but can't
>>>>       remember
>>>>          the details.  Anyone remember?  An svn link is fine.
>>>>
>>>>
>>>>          -David
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>       --        Gurkan Erdogdu
>>>>       http://gurkanerdogdu.blogspot.com
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Gurkan Erdogdu
>>>> http://gurkanerdogdu.blogspot.com
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Gurkan Erdogdu
>>>> http://gurkanerdogdu.blogspot.com
>>>>
>>>
>>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>
>
>
> --
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by David Jencks <da...@yahoo.com>.
Hi Gurkan,

to get a ModuleBuilderExtension to do anything it has to be associated  
with a ModuleBuilder for a type of ee app which will call it at the  
appropriate points during deployment.  I'm not sure what kinds of ee  
modules web beans can included in, but I added the OWBMBE to the  
jetty7 and tomcat6 builders in rev 806989.  If this is not quite right  
you should be able to figure out what to do with other module builders.

hope this is in the right direction :-)

thanks
david jencks

On Aug 23, 2009, at 5:32 AM, Gurkan Erdogdu wrote:

> Hi David;
>
> I have deployed plugins(2 car ) into the server. Server calls  
> OpenWebBeansModuleBuilderExtension while it starts. But it never  
> calls "createModule, addGBeans" methods. Do I have to configure  
> something for this?
>
> Thanks;
>
> --Gurkan
>
> 2009/8/22 Gurkan Erdogdu <cg...@gmail.com>
> Great help David!
>
> Thanks a lot. I will try to fill the blanks.
>
> --Gurkan
>
> 2009/8/22 David Blevins <da...@visi.com>
>
> Great summary, thanks!
>
> So as I mentioned on the OpenEJB list and the reason I kicked the  
> thread over here is that the ServletContextListener approach to  
> scanning doesn't work as none of those things exist at deploy time.
>
> To try and move things forward I've created a basic plugin for  
> OpenWebBeans that can serve as a starting point for the  
> integration.  This will help get us out of the abstract and right  
> down to the nuts and bolts.
>
> DEPLOYMENT
>
> Long story short, the code that scans the managed bean classes for  
> @Resource etc. goes here:
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>
> The code to do the @Resource scanning is actually in there already,  
> it's the line like this:
>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,  
> buildingContext);
> What needs to happen in this class is we need to get a complete list  
> of the managed bean classes so they can be scanned by the Geronimo  
> naming builder.  This class is an extension to the Geronimo  
> deployment system, so no webapp objects exist yet.  I know that the  
> OpenWebBeans code doesn't currently work like this and relies on  
> ServetContext and other things.  We will have to find a way to get  
> that to work without the use of any servet APIs.
>
> A bonus is that you can install any servlets or filters or listeners  
> you like into the webapp so when it boots, anything you'd like to  
> add will be there without the user having to add it.  A pretty cool  
> advantage to being part of the deployment system.  I've got some  
> code in there that adds a ServletContextListener -- I left the  
> classname of the listener blank, you just need to fill it in.
>
> For a great example of what the JSF deployer extension looks like,  
> see this class:
>
>
> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>
>
> RUNTIME
>
> Here's where you can add any startup and shutdown code you'd like:
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>
> This will be guaranteed to run just before the webapp starts up and  
> stop just after the webapp stops.  Great place for initialization  
> code and taking care of getting any hooks into Geronimo that you  
> might need/want for while the webapp is running.
>
> This doesn't tackle everything on the TODO list but is a step in the  
> right direction.
>
> -David
>
>
> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>
> I want to give brief introduction about current implementation in  
> the view of integration points
>
> Brief Summary About Current Situation
> ---------------------------------------------------------
> Currently we bootstrap OpenWebBeans via ServletContextListener. It  
> supports following containers
>
> - Java Web Containers like Jetty, Tomcat etc.
> - Tomcat Embeddable OpenEJB Container
>
> If developer wants to use OWB functionality in his application, it  
> has to configure its "web.xml" to include some OWB specific classes.  
> For EJB functionality, we use embeddable Tomcat OpenEJB container.  
> To use EJB functionality, developer must annotate their EJB classes  
> with OWB specific "Interceptor" class.
>
> How OWB Boots Currently(From integration point of view)
> -------------------------------------------------------
> 1* Web Container calls OWB specific context listener's "application  
> started" method
> 2* OWB container scans related classes from the artifacts (if META- 
> INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker  
> for deployment)
> 3* If developer configures OWB to use EJB functionality, for each  
> scanned class, it asks OpenEJB to learn whether it is an EJB class  
> or not (Using EJB Plugin that is written accroding to the OpenEJB)
> 4* If it is an EJB class, it creates EJB bean and register it with  
> the OWB container otherwise if it is a Java EE defined Managed Bean  
> Class, it creates a "Managed Bean" and register it with the OWB  
> container.
>
> Developer Responsibility to Use OWB
> --------------------------------------------------------
> 1* Add servlet context listener to his web module's "web.xml"
> 2* Annotate EJB classes with OWB interceptor
> 3* Configure OWB container to use EJB functionality
> 4* Configure some OWB specific parameters (For example : if use JMS  
> injections, specify ConnectionFactory JNDI name)
>
> Current Problems
> -----------------------------------------------------
> 1* Currently we just support "WAR" module with embeddable EJB.
> 2* Developer requires to update WAR/EJB module metadata files to use  
> OWB.
> 3* Standalone EJB JAR,RAR, EAR not supported
> 4* Injections into "Managed Beans" class not well supported. (For  
> example : @Resource, @WebServiceRef, @EJB,  
> @PersistenceUnit,@PersistenceContext.)
>
> How Could We Integrate with Geronimo
> ---------------------------------------------------------
> 1* Geronimo looks for deployment. If it contains "beans.xml", it  
> automatically registers OWB servlet context listener with WAR's  
> web.xml at deployment time
> 2* Automatically registers OWB EJB interceptor with EJBs at  
> deployment time (If module is EJB module or EAR module containing  
> EJB modules)
> 3* Support EJB JAR, EAR, RAR modules
> 4* Write EJB Plugin for Geronimo
> 5* Supports injections for Managed Beans
>
> I hope this helps a bit more
>
> Thanks;
>
> --Gurkan
>
> 2009/8/20 Rick McGuire <ri...@gmail.com>
> Gurkan Erdogdu wrote:
> >>>We'd be interested in any details about what integration work  
> might be needed to add this to Geronimo.
> It is a really fascinating thing that you support us to finish  
> implementation and pass TCK :) We really need a help.
> I think there is a great willingness to help you with this, but I  
> was looking form something more specific, such as the actual areas/ 
> functions where integration assistance is needed.
> Rick
>
>
> Thanks;
>
> --Gurkan
>
> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>
>
>   Gurkan Erdogdu wrote:
>
>       Hi;
>
>       Thanks for kicking discussion David.
>
>       As you may already know Java EE 6 will be planned to release
>       on  November. Do you have any plan or roadmap  to integrate
>       JSR-299 with Geronimo?
>
>   We have a tentative roadmap for implementing the Web Profile at:
>
>   http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>
>   For the JEE6 plans, the web profile did not include JSR 299, which
>   I guess has changed recently.  We'd be interested in any details
>   about what integration work might be needed to add this to Geronimo.
>   Rick
>
>
>       We are working hard to implement full specification but it has
>       some parts that requires to integrate with Java EE server  
> tightly.
>
>       Thanks;
>
>       --Gurkan
>
>       2009/8/20 David Blevins <david.blevins@visi.com
>       <ma...@visi.com> <mailto:david.blevins@visi.com
>
>       <ma...@visi.com>>>
>
>
>          I've been talking with Gurkan of OpenWebBeans over on the
>       OpenEJB
>          list and it seemed like a good idea to kick the thread over
>       here
>          as well.
>
>          The long and short of it is that we'll need to scan 299  
> managed
>          beans at deploy time exactly as we do for JSF.
>
>          Wanted to point him at the JSF scanning code, but can't
>       remember
>          the details.  Anyone remember?  An svn link is fine.
>
>
>          -David
>
>
>
>
>
>
>       --        Gurkan Erdogdu
>       http://gurkanerdogdu.blogspot.com
>
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com


Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
Hi David;

I have deployed plugins(2 car ) into the server. Server calls
OpenWebBeansModuleBuilderExtension while it starts. But it never calls
"createModule, addGBeans" methods. Do I have to configure something for
this?

Thanks;

--Gurkan

2009/8/22 Gurkan Erdogdu <cg...@gmail.com>

> Great help David!
>
> Thanks a lot. I will try to fill the blanks.
>
> --Gurkan
>
> 2009/8/22 David Blevins <da...@visi.com>
>
> Great summary, thanks!
>>
>> So as I mentioned on the OpenEJB list and the reason I kicked the thread
>> over here is that the ServletContextListener approach to scanning doesn't
>> work as none of those things exist at deploy time.
>>
>> To try and move things forward I've created a basic plugin for
>> OpenWebBeans that can serve as a starting point for the integration.  This
>> will help get us out of the abstract and right down to the nuts and bolts.
>>
>> DEPLOYMENT
>>
>> Long story short, the code that scans the managed bean classes for
>> @Resource etc. goes here:
>>
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>>
>> The code to do the @Resource scanning is actually in there already, it's
>> the line like this:
>>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,
>> buildingContext);
>> What needs to happen in this class is we need to get a complete list of
>> the managed bean classes so they can be scanned by the Geronimo naming
>> builder.  This class is an extension to the Geronimo deployment system, so
>> no webapp objects exist yet.  I know that the OpenWebBeans code doesn't
>> currently work like this and relies on ServetContext and other things.  We
>> will have to find a way to get that to work without the use of any servet
>> APIs.
>>
>> A bonus is that you can install any servlets or filters or listeners you
>> like into the webapp so when it boots, anything you'd like to add will be
>> there without the user having to add it.  A pretty cool advantage to being
>> part of the deployment system.  I've got some code in there that adds a
>> ServletContextListener -- I left the classname of the listener blank, you
>> just need to fill it in.
>>
>> For a great example of what the JSF deployer extension looks like, see
>> this class:
>>
>>
>> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>>
>>
>> RUNTIME
>>
>> Here's where you can add any startup and shutdown code you'd like:
>>
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>>
>> This will be guaranteed to run just before the webapp starts up and stop
>> just after the webapp stops.  Great place for initialization code and taking
>> care of getting any hooks into Geronimo that you might need/want for while
>> the webapp is running.
>>
>> This doesn't tackle everything on the TODO list but is a step in the right
>> direction.
>>
>> -David
>>
>>
>> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>>
>>  I want to give brief introduction about current implementation in the
>>> view of integration points
>>>
>>> Brief Summary About Current Situation
>>> ---------------------------------------------------------
>>> Currently we bootstrap OpenWebBeans via ServletContextListener. It
>>> supports following containers
>>>
>>> - Java Web Containers like Jetty, Tomcat etc.
>>> - Tomcat Embeddable OpenEJB Container
>>>
>>> If developer wants to use OWB functionality in his application, it has to
>>> configure its "web.xml" to include some OWB specific classes. For EJB
>>> functionality, we use embeddable Tomcat OpenEJB container. To use EJB
>>> functionality, developer must annotate their EJB classes with OWB specific
>>> "Interceptor" class.
>>>
>>> How OWB Boots Currently(From integration point of view)
>>> -------------------------------------------------------
>>> 1* Web Container calls OWB specific context listener's "application
>>> started" method
>>> 2* OWB container scans related classes from the artifacts (if
>>> META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
>>> deployment)
>>> 3* If developer configures OWB to use EJB functionality, for each scanned
>>> class, it asks OpenEJB to learn whether it is an EJB class or not (Using EJB
>>> Plugin that is written accroding to the OpenEJB)
>>> 4* If it is an EJB class, it creates EJB bean and register it with the
>>> OWB container otherwise if it is a Java EE defined Managed Bean Class, it
>>> creates a "Managed Bean" and register it with the OWB container.
>>>
>>> Developer Responsibility to Use OWB
>>> --------------------------------------------------------
>>> 1* Add servlet context listener to his web module's "web.xml"
>>> 2* Annotate EJB classes with OWB interceptor
>>> 3* Configure OWB container to use EJB functionality
>>> 4* Configure some OWB specific parameters (For example : if use JMS
>>> injections, specify ConnectionFactory JNDI name)
>>>
>>> Current Problems
>>> -----------------------------------------------------
>>> 1* Currently we just support "WAR" module with embeddable EJB.
>>> 2* Developer requires to update WAR/EJB module metadata files to use OWB.
>>> 3* Standalone EJB JAR,RAR, EAR not supported
>>> 4* Injections into "Managed Beans" class not well supported. (For example
>>> : @Resource, @WebServiceRef, @EJB, @PersistenceUnit,@PersistenceContext.)
>>>
>>> How Could We Integrate with Geronimo
>>> ---------------------------------------------------------
>>> 1* Geronimo looks for deployment. If it contains "beans.xml", it
>>> automatically registers OWB servlet context listener with WAR's web.xml at
>>> deployment time
>>> 2* Automatically registers OWB EJB interceptor with EJBs at deployment
>>> time (If module is EJB module or EAR module containing EJB modules)
>>> 3* Support EJB JAR, EAR, RAR modules
>>> 4* Write EJB Plugin for Geronimo
>>> 5* Supports injections for Managed Beans
>>>
>>> I hope this helps a bit more
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>>> Gurkan Erdogdu wrote:
>>> >>>We'd be interested in any details about what integration work might be
>>> needed to add this to Geronimo.
>>> It is a really fascinating thing that you support us to finish
>>> implementation and pass TCK :) We really need a help.
>>> I think there is a great willingness to help you with this, but I was
>>> looking form something more specific, such as the actual areas/functions
>>> where integration assistance is needed.
>>> Rick
>>>
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>>
>>>
>>>   Gurkan Erdogdu wrote:
>>>
>>>       Hi;
>>>
>>>       Thanks for kicking discussion David.
>>>
>>>       As you may already know Java EE 6 will be planned to release
>>>       on  November. Do you have any plan or roadmap  to integrate
>>>       JSR-299 with Geronimo?
>>>
>>>   We have a tentative roadmap for implementing the Web Profile at:
>>>
>>>
>>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>>
>>>   For the JEE6 plans, the web profile did not include JSR 299, which
>>>   I guess has changed recently.  We'd be interested in any details
>>>   about what integration work might be needed to add this to Geronimo.
>>>   Rick
>>>
>>>
>>>       We are working hard to implement full specification but it has
>>>       some parts that requires to integrate with Java EE server tightly.
>>>
>>>       Thanks;
>>>
>>>       --Gurkan
>>>
>>>       2009/8/20 David Blevins <david.blevins@visi.com
>>>       <ma...@visi.com> <mailto:david.blevins@visi.com
>>>
>>>       <ma...@visi.com>>>
>>>
>>>
>>>          I've been talking with Gurkan of OpenWebBeans over on the
>>>       OpenEJB
>>>          list and it seemed like a good idea to kick the thread over
>>>       here
>>>          as well.
>>>
>>>          The long and short of it is that we'll need to scan 299 managed
>>>          beans at deploy time exactly as we do for JSF.
>>>
>>>          Wanted to point him at the JSF scanning code, but can't
>>>       remember
>>>          the details.  Anyone remember?  An svn link is fine.
>>>
>>>
>>>          -David
>>>
>>>
>>>
>>>
>>>
>>>
>>>       --        Gurkan Erdogdu
>>>       http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>
>>
>
>
> --
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>



-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
Great help David!

Thanks a lot. I will try to fill the blanks.

--Gurkan

2009/8/22 David Blevins <da...@visi.com>

> Great summary, thanks!
>
> So as I mentioned on the OpenEJB list and the reason I kicked the thread
> over here is that the ServletContextListener approach to scanning doesn't
> work as none of those things exist at deploy time.
>
> To try and move things forward I've created a basic plugin for OpenWebBeans
> that can serve as a starting point for the integration.  This will help get
> us out of the abstract and right down to the nuts and bolts.
>
> DEPLOYMENT
>
> Long story short, the code that scans the managed bean classes for
> @Resource etc. goes here:
>
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>
> The code to do the @Resource scanning is actually in there already, it's
> the line like this:
>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,
> buildingContext);
> What needs to happen in this class is we need to get a complete list of the
> managed bean classes so they can be scanned by the Geronimo naming builder.
>  This class is an extension to the Geronimo deployment system, so no webapp
> objects exist yet.  I know that the OpenWebBeans code doesn't currently work
> like this and relies on ServetContext and other things.  We will have to
> find a way to get that to work without the use of any servet APIs.
>
> A bonus is that you can install any servlets or filters or listeners you
> like into the webapp so when it boots, anything you'd like to add will be
> there without the user having to add it.  A pretty cool advantage to being
> part of the deployment system.  I've got some code in there that adds a
> ServletContextListener -- I left the classname of the listener blank, you
> just need to fill it in.
>
> For a great example of what the JSF deployer extension looks like, see this
> class:
>
>
> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>
>
> RUNTIME
>
> Here's where you can add any startup and shutdown code you'd like:
>
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>
> This will be guaranteed to run just before the webapp starts up and stop
> just after the webapp stops.  Great place for initialization code and taking
> care of getting any hooks into Geronimo that you might need/want for while
> the webapp is running.
>
> This doesn't tackle everything on the TODO list but is a step in the right
> direction.
>
> -David
>
>
> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>
>  I want to give brief introduction about current implementation in the view
>> of integration points
>>
>> Brief Summary About Current Situation
>> ---------------------------------------------------------
>> Currently we bootstrap OpenWebBeans via ServletContextListener. It
>> supports following containers
>>
>> - Java Web Containers like Jetty, Tomcat etc.
>> - Tomcat Embeddable OpenEJB Container
>>
>> If developer wants to use OWB functionality in his application, it has to
>> configure its "web.xml" to include some OWB specific classes. For EJB
>> functionality, we use embeddable Tomcat OpenEJB container. To use EJB
>> functionality, developer must annotate their EJB classes with OWB specific
>> "Interceptor" class.
>>
>> How OWB Boots Currently(From integration point of view)
>> -------------------------------------------------------
>> 1* Web Container calls OWB specific context listener's "application
>> started" method
>> 2* OWB container scans related classes from the artifacts (if
>> META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
>> deployment)
>> 3* If developer configures OWB to use EJB functionality, for each scanned
>> class, it asks OpenEJB to learn whether it is an EJB class or not (Using EJB
>> Plugin that is written accroding to the OpenEJB)
>> 4* If it is an EJB class, it creates EJB bean and register it with the OWB
>> container otherwise if it is a Java EE defined Managed Bean Class, it
>> creates a "Managed Bean" and register it with the OWB container.
>>
>> Developer Responsibility to Use OWB
>> --------------------------------------------------------
>> 1* Add servlet context listener to his web module's "web.xml"
>> 2* Annotate EJB classes with OWB interceptor
>> 3* Configure OWB container to use EJB functionality
>> 4* Configure some OWB specific parameters (For example : if use JMS
>> injections, specify ConnectionFactory JNDI name)
>>
>> Current Problems
>> -----------------------------------------------------
>> 1* Currently we just support "WAR" module with embeddable EJB.
>> 2* Developer requires to update WAR/EJB module metadata files to use OWB.
>> 3* Standalone EJB JAR,RAR, EAR not supported
>> 4* Injections into "Managed Beans" class not well supported. (For example
>> : @Resource, @WebServiceRef, @EJB, @PersistenceUnit,@PersistenceContext.)
>>
>> How Could We Integrate with Geronimo
>> ---------------------------------------------------------
>> 1* Geronimo looks for deployment. If it contains "beans.xml", it
>> automatically registers OWB servlet context listener with WAR's web.xml at
>> deployment time
>> 2* Automatically registers OWB EJB interceptor with EJBs at deployment
>> time (If module is EJB module or EAR module containing EJB modules)
>> 3* Support EJB JAR, EAR, RAR modules
>> 4* Write EJB Plugin for Geronimo
>> 5* Supports injections for Managed Beans
>>
>> I hope this helps a bit more
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>> Gurkan Erdogdu wrote:
>> >>>We'd be interested in any details about what integration work might be
>> needed to add this to Geronimo.
>> It is a really fascinating thing that you support us to finish
>> implementation and pass TCK :) We really need a help.
>> I think there is a great willingness to help you with this, but I was
>> looking form something more specific, such as the actual areas/functions
>> where integration assistance is needed.
>> Rick
>>
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>
>>
>>   Gurkan Erdogdu wrote:
>>
>>       Hi;
>>
>>       Thanks for kicking discussion David.
>>
>>       As you may already know Java EE 6 will be planned to release
>>       on  November. Do you have any plan or roadmap  to integrate
>>       JSR-299 with Geronimo?
>>
>>   We have a tentative roadmap for implementing the Web Profile at:
>>
>>
>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>
>>   For the JEE6 plans, the web profile did not include JSR 299, which
>>   I guess has changed recently.  We'd be interested in any details
>>   about what integration work might be needed to add this to Geronimo.
>>   Rick
>>
>>
>>       We are working hard to implement full specification but it has
>>       some parts that requires to integrate with Java EE server tightly.
>>
>>       Thanks;
>>
>>       --Gurkan
>>
>>       2009/8/20 David Blevins <david.blevins@visi.com
>>       <ma...@visi.com> <mailto:david.blevins@visi.com
>>
>>       <ma...@visi.com>>>
>>
>>
>>          I've been talking with Gurkan of OpenWebBeans over on the
>>       OpenEJB
>>          list and it seemed like a good idea to kick the thread over
>>       here
>>          as well.
>>
>>          The long and short of it is that we'll need to scan 299 managed
>>          beans at deploy time exactly as we do for JSF.
>>
>>          Wanted to point him at the JSF scanning code, but can't
>>       remember
>>          the details.  Anyone remember?  An svn link is fine.
>>
>>
>>          -David
>>
>>
>>
>>
>>
>>
>>       --        Gurkan Erdogdu
>>       http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by David Blevins <da...@visi.com>.
On Mar 29, 2010, at 7:02 PM, Shawn Jiang wrote:

> I'd like to work on this.  Is there a JIRA opened for this ?

Not yet.  Feel free to create as many subtasks as you need under this  
jira:

   http://issues.apache.org/jira/browse/GERONIMO-5080

Maybe a good title for this one would be something like "Java EE  
Injection annotation scanning for 299 beans"

And basically the goal is to give Geronimo a list of 299 bean classes  
so that it can scan them for these annotations:

   @Resource
   @EJB
   @PersistenceContext
   @PersistenceUnit
   @WebServiceRef

The code to do the scanning is there in the naming builders, but the  
code to get a list of bean classes is not there.

Bare in mind this task is way bigger than it appears as we currently  
have no code to really bootstrap OpenWebBeans into Geronimo and kick  
of any of the work it needs to do to actually generate that list of  
299 beans.

There's also a requirement which we might want to just ignore  
initially as it might be way too against the Geronimo architecture.   
The trick is that new beans can be added at startup via the  
BeanManager events and Geronimo does not do *any* annotation scanning  
at startup, only at deploy which could be in a completely different  
java process.  I think we might just need to turn a blind eye to that  
detail or it might be too hard to get started as essentially it might  
mean have re-architect Geronimo at a very fundamental level.  Getting  
anything running would be a great step forward.

Anyway, get ready for a challenge :)

-David


Re: Webapp Annotation processing for 299

Posted by Shawn Jiang <ge...@gmail.com>.
I'd like to work on this.  Is there a JIRA opened for this ?

On Tue, Mar 30, 2010 at 9:43 AM, David Blevins <da...@visi.com>wrote:

> Bringing this thread up again as it is still a major TODO and if someone is
> looking for something to work on, it's a very good place.
>
>
> On Aug 21, 2009, at 8:16 PM, David Blevins wrote:
>
>  Great summary, thanks!
>>
>> So as I mentioned on the OpenEJB list and the reason I kicked the thread
>> over here is that the ServletContextListener approach to scanning doesn't
>> work as none of those things exist at deploy time.
>>
>> To try and move things forward I've created a basic plugin for
>> OpenWebBeans that can serve as a starting point for the integration.  This
>> will help get us out of the abstract and right down to the nuts and bolts.
>>
>> DEPLOYMENT
>>
>> Long story short, the code that scans the managed bean classes for
>> @Resource etc. goes here:
>>
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>>
>> The code to do the @Resource scanning is actually in there already, it's
>> the line like this:
>>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,
>> buildingContext);
>> What needs to happen in this class is we need to get a complete list of
>> the managed bean classes so they can be scanned by the Geronimo naming
>> builder.  This class is an extension to the Geronimo deployment system, so
>> no webapp objects exist yet.  I know that the OpenWebBeans code doesn't
>> currently work like this and relies on ServetContext and other things.  We
>> will have to find a way to get that to work without the use of any servet
>> APIs.
>>
>> A bonus is that you can install any servlets or filters or listeners you
>> like into the webapp so when it boots, anything you'd like to add will be
>> there without the user having to add it.  A pretty cool advantage to being
>> part of the deployment system.  I've got some code in there that adds a
>> ServletContextListener -- I left the classname of the listener blank, you
>> just need to fill it in.
>>
>> For a great example of what the JSF deployer extension looks like, see
>> this class:
>>
>>
>> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>>
>>
>> RUNTIME
>>
>> Here's where you can add any startup and shutdown code you'd like:
>>
>>
>> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>>
>> This will be guaranteed to run just before the webapp starts up and stop
>> just after the webapp stops.  Great place for initialization code and taking
>> care of getting any hooks into Geronimo that you might need/want for while
>> the webapp is running.
>>
>> This doesn't tackle everything on the TODO list but is a step in the right
>> direction.
>>
>> -David
>>
>> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>>
>>  I want to give brief introduction about current implementation in the
>>> view of integration points
>>>
>>> Brief Summary About Current Situation
>>> ---------------------------------------------------------
>>> Currently we bootstrap OpenWebBeans via ServletContextListener. It
>>> supports following containers
>>>
>>> - Java Web Containers like Jetty, Tomcat etc.
>>> - Tomcat Embeddable OpenEJB Container
>>>
>>> If developer wants to use OWB functionality in his application, it has to
>>> configure its "web.xml" to include some OWB specific classes. For EJB
>>> functionality, we use embeddable Tomcat OpenEJB container. To use EJB
>>> functionality, developer must annotate their EJB classes with OWB specific
>>> "Interceptor" class.
>>>
>>> How OWB Boots Currently(From integration point of view)
>>> -------------------------------------------------------
>>> 1* Web Container calls OWB specific context listener's "application
>>> started" method
>>> 2* OWB container scans related classes from the artifacts (if
>>> META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
>>> deployment)
>>> 3* If developer configures OWB to use EJB functionality, for each scanned
>>> class, it asks OpenEJB to learn whether it is an EJB class or not (Using EJB
>>> Plugin that is written accroding to the OpenEJB)
>>> 4* If it is an EJB class, it creates EJB bean and register it with the
>>> OWB container otherwise if it is a Java EE defined Managed Bean Class, it
>>> creates a "Managed Bean" and register it with the OWB container.
>>>
>>> Developer Responsibility to Use OWB
>>> --------------------------------------------------------
>>> 1* Add servlet context listener to his web module's "web.xml"
>>> 2* Annotate EJB classes with OWB interceptor
>>> 3* Configure OWB container to use EJB functionality
>>> 4* Configure some OWB specific parameters (For example : if use JMS
>>> injections, specify ConnectionFactory JNDI name)
>>>
>>> Current Problems
>>> -----------------------------------------------------
>>> 1* Currently we just support "WAR" module with embeddable EJB.
>>> 2* Developer requires to update WAR/EJB module metadata files to use OWB.
>>> 3* Standalone EJB JAR,RAR, EAR not supported
>>> 4* Injections into "Managed Beans" class not well supported. (For example
>>> : @Resource, @WebServiceRef, @EJB, @PersistenceUnit,@PersistenceContext.)
>>>
>>> How Could We Integrate with Geronimo
>>> ---------------------------------------------------------
>>> 1* Geronimo looks for deployment. If it contains "beans.xml", it
>>> automatically registers OWB servlet context listener with WAR's web.xml at
>>> deployment time
>>> 2* Automatically registers OWB EJB interceptor with EJBs at deployment
>>> time (If module is EJB module or EAR module containing EJB modules)
>>> 3* Support EJB JAR, EAR, RAR modules
>>> 4* Write EJB Plugin for Geronimo
>>> 5* Supports injections for Managed Beans
>>>
>>> I hope this helps a bit more
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>>> Gurkan Erdogdu wrote:
>>> >>>We'd be interested in any details about what integration work might be
>>> needed to add this to Geronimo.
>>> It is a really fascinating thing that you support us to finish
>>> implementation and pass TCK :) We really need a help.
>>> I think there is a great willingness to help you with this, but I was
>>> looking form something more specific, such as the actual areas/functions
>>> where integration assistance is needed.
>>> Rick
>>>
>>>
>>> Thanks;
>>>
>>> --Gurkan
>>>
>>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>>
>>>
>>>  Gurkan Erdogdu wrote:
>>>
>>>      Hi;
>>>
>>>      Thanks for kicking discussion David.
>>>
>>>      As you may already know Java EE 6 will be planned to release
>>>      on  November. Do you have any plan or roadmap  to integrate
>>>      JSR-299 with Geronimo?
>>>
>>>  We have a tentative roadmap for implementing the Web Profile at:
>>>
>>>
>>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>>
>>>  For the JEE6 plans, the web profile did not include JSR 299, which
>>>  I guess has changed recently.  We'd be interested in any details
>>>  about what integration work might be needed to add this to Geronimo.
>>>  Rick
>>>
>>>
>>>      We are working hard to implement full specification but it has
>>>      some parts that requires to integrate with Java EE server tightly.
>>>
>>>      Thanks;
>>>
>>>      --Gurkan
>>>
>>>      2009/8/20 David Blevins <david.blevins@visi.com
>>>      <ma...@visi.com> <mailto:david.blevins@visi.com
>>>
>>>      <ma...@visi.com>>>
>>>
>>>
>>>         I've been talking with Gurkan of OpenWebBeans over on the
>>>      OpenEJB
>>>         list and it seemed like a good idea to kick the thread over
>>>      here
>>>         as well.
>>>
>>>         The long and short of it is that we'll need to scan 299 managed
>>>         beans at deploy time exactly as we do for JSF.
>>>
>>>         Wanted to point him at the JSF scanning code, but can't
>>>      remember
>>>         the details.  Anyone remember?  An svn link is fine.
>>>
>>>
>>>         -David
>>>
>>>
>>>
>>>
>>>
>>>
>>>      --        Gurkan Erdogdu
>>>      http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>>
>>>
>>>
>>> --
>>> Gurkan Erdogdu
>>> http://gurkanerdogdu.blogspot.com
>>>
>>
>>
>>
>


-- 
Shawn

Re: Webapp Annotation processing for 299

Posted by David Blevins <da...@visi.com>.
Bringing this thread up again as it is still a major TODO and if  
someone is looking for something to work on, it's a very good place.

On Aug 21, 2009, at 8:16 PM, David Blevins wrote:

> Great summary, thanks!
>
> So as I mentioned on the OpenEJB list and the reason I kicked the  
> thread over here is that the ServletContextListener approach to  
> scanning doesn't work as none of those things exist at deploy time.
>
> To try and move things forward I've created a basic plugin for  
> OpenWebBeans that can serve as a starting point for the  
> integration.  This will help get us out of the abstract and right  
> down to the nuts and bolts.
>
> DEPLOYMENT
>
> Long story short, the code that scans the managed bean classes for  
> @Resource etc. goes here:
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans-builder/src/main/java/org/apache/geronimo/openwebbeans/deployment/OpenWebBeansModuleBuilderExtension.java
>
> The code to do the @Resource scanning is actually in there already,  
> it's the line like this:
>  namingBuilders.buildNaming(webApp, jettyWebApp, webModule,  
> buildingContext);
> What needs to happen in this class is we need to get a complete list  
> of the managed bean classes so they can be scanned by the Geronimo  
> naming builder.  This class is an extension to the Geronimo  
> deployment system, so no webapp objects exist yet.  I know that the  
> OpenWebBeans code doesn't currently work like this and relies on  
> ServetContext and other things.  We will have to find a way to get  
> that to work without the use of any servet APIs.
>
> A bonus is that you can install any servlets or filters or listeners  
> you like into the webapp so when it boots, anything you'd like to  
> add will be there without the user having to add it.  A pretty cool  
> advantage to being part of the deployment system.  I've got some  
> code in there that adds a ServletContextListener -- I left the  
> classname of the listener blank, you just need to fill it in.
>
> For a great example of what the JSF deployer extension looks like,  
> see this class:
>
> https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>
>
> RUNTIME
>
> Here's where you can add any startup and shutdown code you'd like:
>
> http://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/openwebbeans/geronimo-openwebbeans/src/main/java/org/apache/geronimo/openwebbeans/OpenWebBeansGBean.java
>
> This will be guaranteed to run just before the webapp starts up and  
> stop just after the webapp stops.  Great place for initialization  
> code and taking care of getting any hooks into Geronimo that you  
> might need/want for while the webapp is running.
>
> This doesn't tackle everything on the TODO list but is a step in the  
> right direction.
>
> -David
>
> On Aug 20, 2009, at 8:01 AM, Gurkan Erdogdu wrote:
>
>> I want to give brief introduction about current implementation in  
>> the view of integration points
>>
>> Brief Summary About Current Situation
>> ---------------------------------------------------------
>> Currently we bootstrap OpenWebBeans via ServletContextListener. It  
>> supports following containers
>>
>> - Java Web Containers like Jetty, Tomcat etc.
>> - Tomcat Embeddable OpenEJB Container
>>
>> If developer wants to use OWB functionality in his application, it  
>> has to configure its "web.xml" to include some OWB specific  
>> classes. For EJB functionality, we use embeddable Tomcat OpenEJB  
>> container. To use EJB functionality, developer must annotate their  
>> EJB classes with OWB specific "Interceptor" class.
>>
>> How OWB Boots Currently(From integration point of view)
>> -------------------------------------------------------
>> 1* Web Container calls OWB specific context listener's "application  
>> started" method
>> 2* OWB container scans related classes from the artifacts (if META- 
>> INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker  
>> for deployment)
>> 3* If developer configures OWB to use EJB functionality, for each  
>> scanned class, it asks OpenEJB to learn whether it is an EJB class  
>> or not (Using EJB Plugin that is written accroding to the OpenEJB)
>> 4* If it is an EJB class, it creates EJB bean and register it with  
>> the OWB container otherwise if it is a Java EE defined Managed Bean  
>> Class, it creates a "Managed Bean" and register it with the OWB  
>> container.
>>
>> Developer Responsibility to Use OWB
>> --------------------------------------------------------
>> 1* Add servlet context listener to his web module's "web.xml"
>> 2* Annotate EJB classes with OWB interceptor
>> 3* Configure OWB container to use EJB functionality
>> 4* Configure some OWB specific parameters (For example : if use JMS  
>> injections, specify ConnectionFactory JNDI name)
>>
>> Current Problems
>> -----------------------------------------------------
>> 1* Currently we just support "WAR" module with embeddable EJB.
>> 2* Developer requires to update WAR/EJB module metadata files to  
>> use OWB.
>> 3* Standalone EJB JAR,RAR, EAR not supported
>> 4* Injections into "Managed Beans" class not well supported. (For  
>> example : @Resource, @WebServiceRef, @EJB,  
>> @PersistenceUnit,@PersistenceContext.)
>>
>> How Could We Integrate with Geronimo
>> ---------------------------------------------------------
>> 1* Geronimo looks for deployment. If it contains "beans.xml", it  
>> automatically registers OWB servlet context listener with WAR's  
>> web.xml at deployment time
>> 2* Automatically registers OWB EJB interceptor with EJBs at  
>> deployment time (If module is EJB module or EAR module containing  
>> EJB modules)
>> 3* Support EJB JAR, EAR, RAR modules
>> 4* Write EJB Plugin for Geronimo
>> 5* Supports injections for Managed Beans
>>
>> I hope this helps a bit more
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <ri...@gmail.com>
>> Gurkan Erdogdu wrote:
>> >>>We'd be interested in any details about what integration work  
>> might be needed to add this to Geronimo.
>> It is a really fascinating thing that you support us to finish  
>> implementation and pass TCK :) We really need a help.
>> I think there is a great willingness to help you with this, but I  
>> was looking form something more specific, such as the actual areas/ 
>> functions where integration assistance is needed.
>> Rick
>>
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>
>>
>>   Gurkan Erdogdu wrote:
>>
>>       Hi;
>>
>>       Thanks for kicking discussion David.
>>
>>       As you may already know Java EE 6 will be planned to release
>>       on  November. Do you have any plan or roadmap  to integrate
>>       JSR-299 with Geronimo?
>>
>>   We have a tentative roadmap for implementing the Web Profile at:
>>
>>   http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>
>>   For the JEE6 plans, the web profile did not include JSR 299, which
>>   I guess has changed recently.  We'd be interested in any details
>>   about what integration work might be needed to add this to  
>> Geronimo.
>>   Rick
>>
>>
>>       We are working hard to implement full specification but it has
>>       some parts that requires to integrate with Java EE server  
>> tightly.
>>
>>       Thanks;
>>
>>       --Gurkan
>>
>>       2009/8/20 David Blevins <david.blevins@visi.com
>>       <ma...@visi.com> <mailto:david.blevins@visi.com
>>
>>       <ma...@visi.com>>>
>>
>>
>>          I've been talking with Gurkan of OpenWebBeans over on the
>>       OpenEJB
>>          list and it seemed like a good idea to kick the thread over
>>       here
>>          as well.
>>
>>          The long and short of it is that we'll need to scan 299  
>> managed
>>          beans at deploy time exactly as we do for JSF.
>>
>>          Wanted to point him at the JSF scanning code, but can't
>>       remember
>>          the details.  Anyone remember?  An svn link is fine.
>>
>>
>>          -David
>>
>>
>>
>>
>>
>>
>>       --        Gurkan Erdogdu
>>       http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>> -- 
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>
>


Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
I want to give brief introduction about current implementation in the view
of integration points

Brief Summary About Current Situation
---------------------------------------------------------
Currently we bootstrap OpenWebBeans via ServletContextListener. It supports
following containers

- Java Web Containers like Jetty, Tomcat etc.
- Tomcat Embeddable OpenEJB Container

If developer wants to use OWB functionality in his application, it has to
configure its "web.xml" to include some OWB specific classes. For EJB
functionality, we use embeddable Tomcat OpenEJB container. To use EJB
functionality, developer must annotate their EJB classes with OWB specific
"Interceptor" class.

How OWB Boots Currently(From integration point of view)
-------------------------------------------------------
1* Web Container calls OWB specific context listener's "application started"
method
2* OWB container scans related classes from the artifacts (if
META-INF/beans.xml, or WEB-INF/beans.xml exists. beans.xml is a marker for
deployment)
3* If developer configures OWB to use EJB functionality, for each scanned
class, it asks OpenEJB to learn whether it is an EJB class or not (Using EJB
Plugin that is written accroding to the OpenEJB)
4* If it is an EJB class, it creates EJB bean and register it with the OWB
container otherwise if it is a Java EE defined Managed Bean Class, it
creates a "Managed Bean" and register it with the OWB container.

Developer Responsibility to Use OWB
--------------------------------------------------------
1* Add servlet context listener to his web module's "web.xml"
2* Annotate EJB classes with OWB interceptor
3* Configure OWB container to use EJB functionality
4* Configure some OWB specific parameters (For example : if use JMS
injections, specify ConnectionFactory JNDI name)

Current Problems
-----------------------------------------------------
1* Currently we just support "WAR" module with embeddable EJB.
2* Developer requires to update WAR/EJB module metadata files to use OWB.
3* Standalone EJB JAR,RAR, EAR not supported
4* Injections into "Managed Beans" class not well supported. (For example :
@Resource, @WebServiceRef, @EJB, @PersistenceUnit,@PersistenceContext.)

How Could We Integrate with Geronimo
---------------------------------------------------------
1* Geronimo looks for deployment. If it contains "beans.xml", it
automatically registers OWB servlet context listener with WAR's web.xml at
deployment time
2* Automatically registers OWB EJB interceptor with EJBs at deployment time
(If module is EJB module or EAR module containing EJB modules)
3* Support EJB JAR, EAR, RAR modules
4* Write EJB Plugin for Geronimo
5* Supports injections for Managed Beans

I hope this helps a bit more

Thanks;

--Gurkan

2009/8/20 Rick McGuire <ri...@gmail.com>

> Gurkan Erdogdu wrote:
>
>> >>>We'd be interested in any details about what integration work might be
>> needed to add this to Geronimo.
>> It is a really fascinating thing that you support us to finish
>> implementation and pass TCK :) We really need a help.
>>
> I think there is a great willingness to help you with this, but I was
> looking form something more specific, such as the actual areas/functions
> where integration assistance is needed.
> Rick
>
>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>>
>>    Gurkan Erdogdu wrote:
>>
>>        Hi;
>>
>>        Thanks for kicking discussion David.
>>
>>        As you may already know Java EE 6 will be planned to release
>>        on  November. Do you have any plan or roadmap  to integrate
>>        JSR-299 with Geronimo?
>>
>>    We have a tentative roadmap for implementing the Web Profile at:
>>
>>
>> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>>
>>    For the JEE6 plans, the web profile did not include JSR 299, which
>>    I guess has changed recently.  We'd be interested in any details
>>    about what integration work might be needed to add this to Geronimo.
>>    Rick
>>
>>
>>        We are working hard to implement full specification but it has
>>        some parts that requires to integrate with Java EE server tightly.
>>
>>        Thanks;
>>
>>        --Gurkan
>>
>>        2009/8/20 David Blevins <david.blevins@visi.com
>>        <ma...@visi.com> <mailto:david.blevins@visi.com
>>        <ma...@visi.com>>>
>>
>>
>>           I've been talking with Gurkan of OpenWebBeans over on the
>>        OpenEJB
>>           list and it seemed like a good idea to kick the thread over
>>        here
>>           as well.
>>
>>           The long and short of it is that we'll need to scan 299 managed
>>           beans at deploy time exactly as we do for JSF.
>>
>>           Wanted to point him at the JSF scanning code, but can't
>>        remember
>>           the details.  Anyone remember?  An svn link is fine.
>>
>>
>>           -David
>>
>>
>>
>>
>>
>>
>>        --        Gurkan Erdogdu
>>        http://gurkanerdogdu.blogspot.com
>>
>>
>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by Rick McGuire <ri...@gmail.com>.
Gurkan Erdogdu wrote:
> >>>We'd be interested in any details about what integration work might 
> be needed to add this to Geronimo.
> It is a really fascinating thing that you support us to finish 
> implementation and pass TCK :) We really need a help.
I think there is a great willingness to help you with this, but I was 
looking form something more specific, such as the actual areas/functions 
where integration assistance is needed. 

Rick

>
> Thanks;
>
> --Gurkan
>
> 2009/8/20 Rick McGuire <rickmcg@gmail.com <ma...@gmail.com>>
>
>     Gurkan Erdogdu wrote:
>
>         Hi;
>
>         Thanks for kicking discussion David.
>
>         As you may already know Java EE 6 will be planned to release
>         on  November. Do you have any plan or roadmap  to integrate
>         JSR-299 with Geronimo?
>
>     We have a tentative roadmap for implementing the Web Profile at:
>
>     http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>
>     For the JEE6 plans, the web profile did not include JSR 299, which
>     I guess has changed recently.  We'd be interested in any details
>     about what integration work might be needed to add this to Geronimo.
>     Rick
>
>
>         We are working hard to implement full specification but it has
>         some parts that requires to integrate with Java EE server tightly.
>
>         Thanks;
>
>         --Gurkan
>
>         2009/8/20 David Blevins <david.blevins@visi.com
>         <ma...@visi.com> <mailto:david.blevins@visi.com
>         <ma...@visi.com>>>
>
>
>            I've been talking with Gurkan of OpenWebBeans over on the
>         OpenEJB
>            list and it seemed like a good idea to kick the thread over
>         here
>            as well.
>
>            The long and short of it is that we'll need to scan 299 managed
>            beans at deploy time exactly as we do for JSF.
>
>            Wanted to point him at the JSF scanning code, but can't
>         remember
>            the details.  Anyone remember?  An svn link is fine.
>
>
>            -David
>
>
>
>
>
>
>         -- 
>         Gurkan Erdogdu
>         http://gurkanerdogdu.blogspot.com
>
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com


Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
>>>We'd be interested in any details about what integration work might be
needed to add this to Geronimo.
It is a really fascinating thing that you support us to finish
implementation and pass TCK :) We really need a help.

Thanks;

--Gurkan

2009/8/20 Rick McGuire <ri...@gmail.com>

> Gurkan Erdogdu wrote:
>
>> Hi;
>>
>> Thanks for kicking discussion David.
>>
>> As you may already know Java EE 6 will be planned to release on  November.
>> Do you have any plan or roadmap  to integrate JSR-299 with Geronimo?
>>
> We have a tentative roadmap for implementing the Web Profile at:
>
>
> http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile
>
> For the JEE6 plans, the web profile did not include JSR 299, which I guess
> has changed recently.  We'd be interested in any details about what
> integration work might be needed to add this to Geronimo.
> Rick
>
>>
>> We are working hard to implement full specification but it has some parts
>> that requires to integrate with Java EE server tightly.
>>
>> Thanks;
>>
>> --Gurkan
>>
>> 2009/8/20 David Blevins <david.blevins@visi.com <mailto:
>> david.blevins@visi.com>>
>>
>>    I've been talking with Gurkan of OpenWebBeans over on the OpenEJB
>>    list and it seemed like a good idea to kick the thread over here
>>    as well.
>>
>>    The long and short of it is that we'll need to scan 299 managed
>>    beans at deploy time exactly as we do for JSF.
>>
>>    Wanted to point him at the JSF scanning code, but can't remember
>>    the details.  Anyone remember?  An svn link is fine.
>>
>>
>>    -David
>>
>>
>>
>>
>>
>>
>> --
>> Gurkan Erdogdu
>> http://gurkanerdogdu.blogspot.com
>>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by Rick McGuire <ri...@gmail.com>.
Gurkan Erdogdu wrote:
> Hi;
>
> Thanks for kicking discussion David.
>
> As you may already know Java EE 6 will be planned to release on  
> November. Do you have any plan or roadmap  to integrate JSR-299 with 
> Geronimo?
We have a tentative roadmap for implementing the Web Profile at:

http://cwiki.apache.org/confluence/display/GMOxDEV/Road+map+for+JEE6+Web+Profile

For the JEE6 plans, the web profile did not include JSR 299, which I 
guess has changed recently.  We'd be interested in any details about 
what integration work might be needed to add this to Geronimo. 

Rick
>
> We are working hard to implement full specification but it has some 
> parts that requires to integrate with Java EE server tightly.
>
> Thanks;
>
> --Gurkan
>
> 2009/8/20 David Blevins <david.blevins@visi.com 
> <ma...@visi.com>>
>
>     I've been talking with Gurkan of OpenWebBeans over on the OpenEJB
>     list and it seemed like a good idea to kick the thread over here
>     as well.
>
>     The long and short of it is that we'll need to scan 299 managed
>     beans at deploy time exactly as we do for JSF.
>
>     Wanted to point him at the JSF scanning code, but can't remember
>     the details.  Anyone remember?  An svn link is fine.
>
>
>     -David
>
>
>
>
>
>
> -- 
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com


Re: Webapp Annotation processing for 299

Posted by Gurkan Erdogdu <cg...@gmail.com>.
Hi;

Thanks for kicking discussion David.

As you may already know Java EE 6 will be planned to release on  November.
Do you have any plan or roadmap  to integrate JSR-299 with Geronimo?

We are working hard to implement full specification but it has some parts
that requires to integrate with Java EE server tightly.

Thanks;

--Gurkan

2009/8/20 David Blevins <da...@visi.com>

> I've been talking with Gurkan of OpenWebBeans over on the OpenEJB list and
> it seemed like a good idea to kick the thread over here as well.
>
> The long and short of it is that we'll need to scan 299 managed beans at
> deploy time exactly as we do for JSF.
>
> Wanted to point him at the JSF scanning code, but can't remember the
> details.  Anyone remember?  An svn link is fine.
>
>
> -David
>
>
>
>


-- 
Gurkan Erdogdu
http://gurkanerdogdu.blogspot.com

Re: Webapp Annotation processing for 299

Posted by Shawn Jiang <ge...@gmail.com>.
IIUC, Geronimo use myfaces as it's JSF implementation.  The related code
resides in
https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces

The specific code to parse the myface config to get the managedBean classes
is:

https://svn.apache.org/repos/asf/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java

On Thu, Aug 20, 2009 at 5:55 AM, David Blevins <da...@visi.com>wrote:

> I've been talking with Gurkan of OpenWebBeans over on the OpenEJB list and
> it seemed like a good idea to kick the thread over here as well.
>
> The long and short of it is that we'll need to scan 299 managed beans at
> deploy time exactly as we do for JSF.
>
> Wanted to point him at the JSF scanning code, but can't remember the
> details.  Anyone remember?  An svn link is fine.
>
>
> -David
>
>
>
>


-- 
Shawn