Vicky Kak wrote:
Hi Folks,

I am in process of testing openwebbean with Tomcat/openejb, I did read the related section from the following docs
https://svn.apache.org/repos/asf/openwebbeans/trunk/readme/README_M3.txt

Here is the section which explains it
********************************************************************************************
EJB Support via Embeddable OpenEJB Container in Tomcat 6.X
---------------------------------------------

Configuration Steps:
--------------------------------------------
1* Download Tomcat 6.X version
2* Configure OpenEJB. Look at URL http://openejb.apache.org/tomcat.html for installation.
3* Copy "atinject-api-1.0.0-incubating-M3.jar" to Tomcat /lib folder.
4* Copy "openwebbeans-api-1.0.0-incubating-M3.jar"
5* Look at ejb-sample.war for "WEB-INF/lib" libraries to develop custom application.
  You can also look at a source of the project.
******************************************************************************************** "atinject-api-1.0.0-incubating-M3.jar" does not get generated at atinject-tck location, I was expecting it to be there. It is not there, I did pull the CDI api jar and dropped it in the $TOMCAT_HOME/lib.

"openwebbeans-api-1.0.0-incubating-M3.jar" should also be copied to the $TOMCAT/lib, this should be pointed in the instructions too.

>>Look at ejb-sample.war for "WEB-INF/lib" libraries to develop custom application.
I don't understand what does this mean, it is not clear.


********************************************************************************************
How to Develop EJB Applications
---------------------------------------------
1* Add "META-INF/openwebbeans.properties" into your application classpath. 2* Add "org.apache.webbeans.spi.deployer.UseEjbMetaDataDiscoveryService=true" to use EJB functionality.
  So OWB container looks for EJBs.
3* Add "org.apache.webbeans.resource.spi.ResourceService=org.apache.webbeans.spi.ee.openejb.resource.OpenEjbResourceServiceImpl" to
use OpenEJB Resource injections.
4* Add "openwebbeans-ejb", "openwebbeans-resource" and "openwebbeans-geronimo" plugins into your web application classpath. It adds EJB, Resource and Open EJB Resource plugins into your application. 5* If you want to use other plugins, add respective plugins into your application classpath. For example, if you wish to use
JSF framework, you add "openwebbeans-jsf" plugin.
6* Add OWB related interceptor into your EJB Beans. This is called "org.apache.webbeans.ejb.interceptor.OpenWebBeansEjbInterceptor"
This is needed for OWB injections.
7* Update your application's "web.xml" to add OWB specific configuration.

---------------------------------------------
********************************************************************************************

Why can't we have this openwebbeans.properties as a part of the jars which we have dropped in $TOMCAT/lib, it is not good idea to configure the classpath for the Tomcat and then start.
I see the default properties file being here
https://svn.apache.org/repos/asf/openwebbeans/trunk/webbeans-impl/src/main/resources/META-INF/openwebbeans/openwebbeans-default.properties

This does not contain the property values as mentioned in "How to Develop EJB Applications", I was thinking of taking the same file setting it to the Tomcat CP.

I have been able to configure the openEJB for Tomcat and have not yet followed the instructions to set the META-INF/openwebbeans.properties and hence getting this error *******************************************************************************
context path = /ejb-sample
23 Feb, 2010 1:33:28 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
*******************************************************************************

Before digging more into the code and finding the details I would like to know more from the community.

Regards,
Vicky



Reply via email to