all groups > macromedia flash flash remoting > december 2003 >
You're in the

macromedia flash flash remoting

group:

Unable to use remoting with root context in Tomcat 5


Unable to use remoting with root context in Tomcat 5 kbirch
12/27/2003 9:28:14 AM
macromedia flash flash remoting:
I have had success using flash remoting with both beans and servlets on Tomcat 5.0 running on Linux. However, I have not been able to interact with a servlet when the web app is at the root context of a virtual host:

<Host name="www.myhost.com" ...>
<Context path="" docBase="www" ...>

I'm assuming the ActionScript for this should be...

NetServices.setDefaultGatewayUrl("http://www.myhost.com/gateway");
serviceConnection = NetServices.createGatewayConnection();
testService = serviceConnection.getService( "", this );

....but I may be wrong and haven't been able to find specific documentation. When I set things up as above I get a peculiar stack trace that starts with "java.lang.NoClassDefFoundError: javax/ejb/EJBHome at flashgateway.adapter.java.EJBAdapter". It makes no sense because under the same service, engine, and host, with only the addition of a subdirectory context...

<Context path="/mycontext" docBase="www" ...>

and

NetServices.setDefaultGatewayUrl("http://www.myhost.com/mycontext/gateway");
serviceConnection = NetServices.createGatewayConnection();
testService = serviceConnection.getService( "mycontext", this );

....it works fine! I have been testing this for hours with all sorts of permutations, and it just won't work at the root level. And yes, I have confirmed that everything is fine with my Tomcat configuration. Is this a bug in the flashgateway, or is there some other syntax for the getService() function when the context is root?

Thanks in advance for your help.

Re: Unable to use remoting with root context in To Cabaalxx
2/10/2004 4:32:31 PM
Re: Unable to use remoting with root context in Tomcat 5 sullis
2/11/2004 8:05:27 PM
Are you using Macromedia's Flash Gateway or the OpenAMF gateway?

AddThis Social Bookmark Button