0 Replies Latest reply on Nov 29, 2012 11:50 AM by dobbo314

    RESTEasy, JBossAS-7.1.1 and EJB injection

    dobbo314

      I've used JBoss-AS before (version 4 mostly) and I like the architecture.  But with a new project use the later version, and RESTEasy looks like it is going to save me a lot of time and is a good fit.  With JBossAS 7.1.1 I can get the entity EJBs to work it seams; they deploy and create the necessary tables in the MySQL database.  I can also get a simple stateful or stateless EJB to deploy - at least I get a list of JINI bindings reported.

       

      I can also get the RESTEasy part to work on its own, but only as far as a simple hello world example. The Apache webserver talks quite happily to the JBossAS server and serves up the hello world content.  What I can't do is get the RESTEasy bit to talk to the stateful or stateless EJBs.  So far I've tried dependency injection, but nothing gets injected, the private EJB field is always NULL.

       

      I've no doubt that it is something simple that I'm not doing.  It is probably a configuration issue.  Something I've missed or haven't known to include.  What I'm really looking for is a simple tutorial that will show me each bit in detail.  Or would it be better to do a context look up?  But a context lookup does feel wrong given that everything is being deployed in the same EAR.

       

      And lastly I would really appreciate it if maven was not part of the equation.  As a developer I really don't like posting "It doesn't work" questions, but with maven that wis what I would have to do, because in the second step of the "Getting Started with Errai and CDI" example the "mvn clean gwt:run" step ends with a:

       

      [ERROR] BUILD ERROR

      [INFO] Failed to configure plugin parameters for: org.jboss.errai:jacoco-gwt-maven-plugin:0.5.4.201202141554

      Cause: Class 'java.util.List' cannot be instantiated

       

      But as I don't want Errai, the web UI doen't call for it I don't really want to get side tracked down that particular path.

       

      Many thanks for any suggestions

      Steve