Hi,

I have installed JBoss with the EJB3 config - I'm just reading things on the net about how JBoss doesn't support the whole JBoss standard. The EJBs are working just fine, it's calling them from a webapp that is giving me problems (I have called them from a Java EE client app without problems). For instance:

public class AServletClass... {

    private @EJB ASessionLocal sessionBean;

    public void processRequest(request, response) {
        sessionBean.doSomething() //this line throws null pointer exception
    }

}

I have been using the exact same syntax inside my session beans, and from all the resources I've seen it should be legal to do this. Unfortunately, I get a null pointer exception, which would make sense if I hadn't initialised sessionBean to anything... but in theory, JBoss should have found the bean I was looking for and created an instance for me.

Any hints anyone?

Regards,
Fritz

On 7/28/06, Lisa Retief <[EMAIL PROTECTED] > wrote:

Hi Fritz,

Please don't go back to the old way. Injection works - we use it
extensively from all over the place.

Because JBoss is J2EE 1.4 compliant, the GA release does not include
EJB3, as this is not part of J2EE 1.4. You need to download the
installer jar and run it, and then specifically select to include EJB3
in the installation.

Hope that helps,
Lisa

On 7/28/06, Fritz Meissner <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> A question: JBoss advertise EJB3 compliance for their latest releases, but
> does the server offer complete support for the Java EE 5 standard? In
> particular, is it possible to use the @EJB annotation on a member field of a
> servlet in the same way as I can in a session bean? The reason I ask is that
> I am trying to get a web app to work using all these cool EE 5 features and
> this one seems to be causing problems. Should I go back to the old and
> complicated way of finding beans in my frontend, or is this not likely the
> problem?
>
> Regards,
> Fritz
>
>  >
>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CTJUG Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/CTJUG-Forum
For the ctjug home page see http://www.ctjug.org.za
-~----------~----~----~----~------~----~------~--~---

Reply via email to