Author: pete.muir(a)jboss.org
Date: 2009-04-07 12:42:31 -0400 (Tue, 07 Apr 2009)
New Revision: 2334
Modified:
doc/trunk/reference/en-US/environments.xml
examples/trunk/tomcat/WebContent/META-INF/context.xml
Log:
Docs/examples for WBX-14
Modified: doc/trunk/reference/en-US/environments.xml
===================================================================
--- doc/trunk/reference/en-US/environments.xml 2009-04-07 16:40:59 UTC (rev 2333)
+++ doc/trunk/reference/en-US/environments.xml 2009-04-07 16:42:31 UTC (rev 2334)
@@ -156,6 +156,15 @@
<literal>java:comp/env</literal>, so the Manager will be available
at
<literal>java:comp/env/app/Manager</literal>
</para>
+
+ <para>
+ Web Beans also supports Servlet injection in Tomcat. To enable this,
+ place the <literal>webbeans-tomcat-support.jar</literal> in
+ <literal>$TOMCAT_HOME/lib</literal>, and add the following to your
+ <literal>META-INF/context.xml</literal>:
+ </para>
+
+ <programlisting><![CDATA[<Listener
className="org.jboss.webbeans.environment.tomcat.WebBeansLifecycleListener"
/>]]></programlisting>
</section>
Modified: examples/trunk/tomcat/WebContent/META-INF/context.xml
===================================================================
--- examples/trunk/tomcat/WebContent/META-INF/context.xml 2009-04-07 16:40:59 UTC (rev
2333)
+++ examples/trunk/tomcat/WebContent/META-INF/context.xml 2009-04-07 16:42:31 UTC (rev
2334)
@@ -1,7 +1,9 @@
<Context>
- <Resource name="app/Manager" auth="Container"
+ <Resource name="app/Manager" auth="Container"
type="javax.inject.manager.Manager"
factory="org.jboss.webbeans.resources.ManagerObjectFactory"/>
- <Listener
className="org.jboss.webbeans.environment.tomcat.WebBeansLifecycleListener"
/>
+<!-- Uncomment to enable injection into Servlet -->
+<!-- <Listener
className="org.jboss.webbeans.environment.tomcat.WebBeansLifecycleListener"
/>-->
+
</Context>
Show replies by date