Community
Participate
Working Groups
Build Identifier: M20101201-0800 I have a class HelloServlet that does extends MyServlet class. I have a DataSource injeced into MyServet that is accessed by HelloServley. The problem is that the value is always null. I don't have this problem with jetty6 Reproducible: Always
Created attachment 185370 [details] MyServlet
Created attachment 185371 [details] HelloServlet
Created attachment 185372 [details] Embedded server
Created attachment 185373 [details] jetty-web
Eclipse project with all needed jars http://dl.dropbox.com/u/5176435/bugs/annotations7.tar.bz2
JNDI objects need to be registered in a jetty-env.xml file, not a jetty-web.xml file. As you can see from the list of Configurations that you have set up in your Embedded server class, the handler for jetty-web.xml runs AFTER the one for jetty-env and the plus/annotations ones. BTW this was the case for jetty-6 too. regards Jan
Hi, I just did what you told me and still does not work. The result is the same. Note that the injection works in the subclass, but not the superclass. ds1=null ds2=oracle.jdbc.pool.OracleConnectionPoolDataSource@3d3c33b7 ds3=oracle.jdbc.pool.OracleConnectionPoolDataSource@21453d72
reopening for investigation
Oh darn! Silly error when iterating over the parent class hierarchy. Fixed in trunk svn rev 2612. Thanks for persisting with the bug report. Jan