Jboss 6 eclipse remote debugging fails for remote session bean injected via JNDI lookup - eclipse

I am using JNDI lookups to inject a remote EJB3 session bean inside my spring 3 controller. Since my web module will run in tomcat and the business layer app in a remote Jboss 6, this configuration was decided. For the development I still use only jboss and my web and ear both are deployed in the same jobss instance (jboss 6). Everything works well for me, but when I tried to debug, all the beans injected returns null, so when in debug view, a null pointer exception is thrown when the remote ejb session bean is invoked. Everything works fine in the run mode (non-debug).
I am using eclipse(Helios) and trying remote debugging
I have the jndi.properties file in my jboss/deploy with these settings
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.provider.url=localhost:1099
java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
any help on this issue...
thanks...

Since remote debugging did not work for me, I used the jboss plugin for eclipse to make the debug process work.

Related

"SEVERE: There is no installed container capable of handling this application" error while trying to deploy EJB jar in glassfish

I am using netbeans 7.2.1 and glassfish 3.1.2 server. I created an ejb project and while trying to deploy the ejb jar in the server, i see the below error in the server log:
SEVERE: Module type not recognized for module C:\Users\AppData\Roaming\NetBeans\7.2.1\config\GF3\domain1\applications\SAPLockBox
SEVERE: There is no installed container capable of handling this application SAPLockBox
The error also points out to
<target if="netbeans.home" name="-run-deploy-nb">
<nbdeploy debugmode="false" forceRedeploy="${forceRedeploy}"/>
</target>
in build-impl.xml. I have read many online posts and tried a few but no success so far.
Have you tried to run your ejb jar file not in your netbeans context, but outside of it?
What Java EE APIs do you use? You may have one, that it is not accessible to the glassfish server, but in netbeans compiles OK.

GWT Deployment to JBoss

I am currently working on a project which has a GWT frontend and a seperate Java module with servlets and a REST interface on the backend. The project when deployed runs on a single JBoss server.
I am running into difficulties though as when I run the GWT app in hosted mode (in eclipse) the jetty server does not have a deployed Java module to interact with.
My idea was to setup a JBoss server which eclipse could deploy into for development purposes, the problem with this is that the installer for the product sets up a JBoss server with a GWT app already embedded in it, so redeploying into this JBoss instance might cause problems?
My other idea would be to create a second JBoss server to host the GWT app, with some sort of url redirect for the rest calls which would redirect to the first JBoss instance. Is this possible?
EDIT: Can I do this with the built in jetty server in eclipse and not have to worry about using a seperate JBoss server. In other words can I somehow get the jetty server in eclipse to redirect particular requests to a different URL?

JBoss 4.0.5 + Equinox + JPA + EclipseLink

I'm trying to connect the JPA (EclipsLink implementation) used on my application to JBoss DS, but don't know how to do it.
The application that I'm working is a OSGi Based application runing on a Equinox container that runs as a servlet on a JBoss WAR file.
How can I configure my application so that it connects the JBoss DS?
Sounds pretty complicated. What have you tried, and what error are you getting?
Normally you just set the datasource in the JPA persistence.xml, does that work?

EJB Server Detection

I would like to detect what server my EJB is running in, particularly between jBoss 6 and Glassfish 3. I have been trying to get the EJBContext from inside an EJB in jBoss without success ("env not bound").
Is there any way at all to get the server name and version, or any other information, from inside an EJB in jBoss 6?
I have been able to get this information from inside a servlet using the servlet context, but I need it inside an EJB.
Thanks

Remote deploy from Eclipse to JBoss AS and integration Eclipse with remote JBoss

I have the following situation. My JBoss server runs on the remote server under some bound address. I would like to run Eclipse on my local machine and deploy results of work to the remote server where I could test it and debug it. I'm working on enterprise Java project and I'm normally deploying one ear file.
I know how to provide remote debugging but what possibilities exist for integrating remove deploy in Eclipse?
I was trying for first the JBoss tools plugin. There is a deploy-only server for the only deploying the project. I'm connected on the network disk on the remote server where JBoss instance runs.
But this plugin deploys ear exploded and afterwards because of the one persistence.xml in my project where tag defines what jars contain entities and instead of the jar there are something.jar directories. Then hibernate isn't able to load entities.
Is there some possibility how to easily make a remote deploy directly from Eclipse? Or better is there possibility how to integrate work on remote JBoss server in Eclipse (I mean run JBoss server, stop it.)?