The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes DI in servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Professional Certification » EJB Certification (SCBCD/OCPJBCD)
Reply Bookmark "DI in servlet" Watch "DI in servlet" New topic
Author

DI in servlet

Kiril Nugmanov
Ranch Hand

Joined: Jul 09, 2008
Posts: 42

Hi all,


Currently i'm preparing for the SCBCD5 (have minor expirience with EJB). I'm really confused with DI in EJB3 - trying to acces local EJB from servlet and allways getting NullPointerException.

Was trying with several application servers Galssfish 2.1.1/3, JBoss 6.0.0.1. JDK version 1.6.0_18

There is my files:

Local interface

EJB

Servlet

DD

Maybe I'm missing something...



This message was edited 1 time. Last update was at by Kiril Nugmanov


SCJP5, SCWCD5, SCBCD5, OCPJWSD5, OCMJEA 5
Jaikiran Pai
Saloon Keeper

Joined: Jul 20, 2005
Posts: 6564

Kiril Nugmanov wrote:



Web-app 2.4 doesn't support injection. You will need 2.5 version of the xsd. See this http://www.coderanch.com/t/426854/EJB-Other-Java-EE-Technologies/java/EJB-doing-nothing-jboss-GA#1894841


[My Blog] [JavaRanch Journal]
Kiril Nugmanov
Ranch Hand

Joined: Jul 09, 2008
Posts: 42

Hi Jaikiran Pai,

Thats was the problem. Thank you.
 
 
subject: DI in servlet
 
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com