openwebbeans-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sagara Gunathunga <>
Subject Issues setting up Openwebbeans Tomcat7 plug-in and Tomcat7-sample
Date Thu, 17 Oct 2013 10:23:47 GMT
Hi Folks,

I managed to setup OWB 1.0.0-alpha-1 Tomcat7 plug-in on Tomcat 7.0.34
server and further tested OWB tomcat7-sample successfully but when I
try to test same sample using OWB Tomcat7 plug-in version 1.2.0 on
same Tomcat version I'm getting following exception.

SEVERE: Servlet.service() for servlet [injector] in context with path
[/tomcat-sample] threw exception
    at org.apache.webbeans.samples.tomcat.MyFilter.doFilter(
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(
    at org.apache.catalina.core.StandardWrapperValve.invoke(
    at org.apache.catalina.core.StandardContextValve.invoke(
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
    at org.apache.catalina.core.StandardHostValve.invoke(
    at org.apache.catalina.valves.ErrorReportValve.invoke(
    at org.apache.catalina.valves.AccessLogValve.invoke(
    at org.apache.catalina.core.StandardEngineValve.invoke(
    at org.apache.catalina.connector.CoyoteAdapter.service(
    at org.apache.coyote.http11.AbstractHttp11Processor.process(
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
    at java.util.concurrent.ThreadPoolExecutor$

It looks like injection of BeanManager instance on MyFilter class[1]  failed.

I have following dependencies on TOMCAT-HOME/lib directory.
├── geronimo-atinject_1.0_spec-1.0.jar
├── geronimo-interceptor_1.1_spec-1.0.jar
├── geronimo-jcdi_1.0_spec-1.0.jar
├── openwebbeans-impl-1.2.0.jar
├── openwebbeans-spi-1.2.0.jar
├── openwebbeans-tomcat7-1.2.0.jar
├── openwebbeans-web-1.2.0.jar

And following dependencies on web application lib  directory (WEB-INF/lib)
├── asm-all-3.1.jar
├── openwebbeans-ee-1.2.0.jar
├── openwebbeans-ee-common-1.2.0.jar
├── openwebbeans-el10-1.2.0.jar
├── openwebbeans-impl-1.2.0.jar
├── openwebbeans-resource-1.2.0.jar
├── openwebbeans-web-1.2.0.jar
├── tomcat-sample.jar
├── xbean-asm-shaded-3.13.jar
└── xbean-finder-3.13.jar

I have added above dependencies according to the guide here[2 ]. FYI I
have following dependencies when i test using OWB 1.0.0-alpha-1
version (Which is the working version for me)

├── geronimo-atinject_1.0_spec-1.0.jar
├── geronimo-interceptor_1.1_spec-1.0.jar
├── geronimo-jcdi_1.0_spec-1.0.jar
├── openwebbeans-spi-1.0.0-alpha-1.jar
├── openwebbeans-tomcat7-1.0.0-alpha-1.jar

wen application lib (WEB-INF/lib)

├── javassist-3.12.1.GA.jar
├── openwebbeans-impl-1.0.0-alpha-1.jar
├── openwebbeans-resource-1.0.0-alpha-1.jar
├── openwebbeans-web-1.0.0-alpha-1.jar
├── scannotation-1.0.2.jar
└── tomcat-sample.jar

I spent several hours on Google/mail archives and testing with number
of Jar file combinations but still no luck, I'm really appreciate if
some one can point me to the right direction to setup OWB 1.2.0
tomcat7 plug-in.

Note : Even with OWB 1.0.0-alpha-1 version I had to remove following
injection from CurrentDateProvider[3] in order to get it work but I
think it's a separate issue.

// private @Inject Principal principal;

[1] -
[2] -
[3] -

Thanks !
Sagara Gunathunga

Blog -
Web -
Linkedin -

View raw message