users@jersey.java.net

Re: [Jersey] which ManagedBean can inject EJB ?

From: Felipe Gaścho <fgaucho_at_gmail.com>
Date: Wed, 21 Oct 2009 18:35:41 +0200

you are injecting integers ??? I am trying to inject @Stateless objects....

is it something like that:

before: @EJB private PujCompetitionFacade facade;
        
after: @Resource(name="injectedResource") private PujCompetitionFacade facade;

??

anyway I follow with the container mess
"com.sun.enterprise.admin.cli.CommandException: remote failure:
Exception while loading the app : java.lang.RuntimeException: EJB
Container initialization error"

in the log:

java.lang.RuntimeException: EJB Container initialization error
        at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:180)
        at com.sun.grizzly.util.FixedThreadPool$BasicWorker.run(FixedThreadPool.java:410)
        at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: Error while binding JNDI name
com.kenai.puj.arena.model.entity.facade.PujCompetitionFacade#com.kenai.puj.arena.model.entity.facade.PujCompetitionFacade
for EJB : PujCompetitionFacadeImpl
        at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:168)
        ... 32 more
Caused by: javax.naming.NameAlreadyBoundException: Use rebind to override