1 Reply Latest reply on Sep 30, 2009 7:18 PM by Ron Sigal

    J2EE remote client HTTP tunneling

    Brad Warren Novice

      I've got a swing client that's making EJB calls and listening to JMS topics in my JBoss app server. I get the server JNDI and do remote proxy lookups for EJBs, JMS Topics, and the JMS Connection Factory.

      All of this works fine until somebody puts a firewall between my client and server and closes everything but port 80. I've been looking and I found quite a bit of possibilities but I didn't really see anything that looked like an exact fit. The closest I saw is JProxy, but testing reveals that it doesn't work. The proxy I got back still wanted to connect on a different port.

      Is JBoss Remoting the way to go here? I could create a server object that proxies the calls to the various EJBs and to JMS and forward the results back to the client. Then tunnel all that over HTTP. My other option would be to convert my JMS code to use HTTP (not looked up from JNDI) and then create web services for my EJB calls. Is there something I'm missing? Maybe there's a way to configure the JNDI proxies to connect back with HTTP tunneling? We're also headed for clustering so I'll have that wrinkle in there soon. The non-firewall answer is to use HA-JNDI and everything else will work fine.

        • 1. Re: J2EE remote client HTTP tunneling
          Ron Sigal Master

           

          "bwarren" wrote:

          Is JBoss Remoting the way to go here?


          Well, as it happens, JBossRemoting is the way you've already gone. EJBs, EJB3s, and JBossMessaging connections all, by default, use JBossRemoting as their transport layer, each, again by default, with their own Remoting servers listening on ports other than 80. However, one of the primary design principles of Remoting is the ability to swap one Remoting transport for another. In your case, you can get closer to your goal with the servlet transport, in which all of the various proxies connect to a Remoting servlet, which then passes the invocations to the appropriate subsystem. Of course, you would need a servlet container (i.e., a JBossWeb (aka Tomcat) connector) listening on port 80. Can you do that? Or will the network powers open up, say, 8080 (the default JBossWeb port in the Application Server - see $JBOSS_HOME/server/$CONFIG/deploy/jboss-web.deployer/server.xml)?

          The configuration details are given in the wiki entry "EJB, JMS and JNDI over HTTP with Unified Invoker" at http://www.jboss.org/community/wiki/EJBJMSandJNDIoverHTTPwithUnifiedInvoker.

          What do you think?