users@glassfish.java.net

Re: How to connect Java SE client to Java EE module running on GlassFish?

From: Dies Koper <diesk_at_fast.au.fujitsu.com>
Date: Mon, 17 Aug 2009 13:32:37 +1000

Hi Witold,

Thanks for your reply.

After sending my e-mail last Saturday I followed Nicklas' link to the
NAT topic you raised two years ago and understood that it was all a bit
more complicated than I initially thought.

You're right, I just tried, the address in the Network Address field is
not only for in the IOR, GF actually tries to bind to it, giving errors
such as the following at start-up time when I try:

[#|2009-08-17T13:21:36.765+1000|SEVERE|sun-appserver2.1|javax.enterprise.resource.corba.ee.S1AS-ORB.rpc.transport|_ThreadID=10;_ThreadName=main;50.50.50.50;3700;;_RequestID=a2abb6fa-2758-471d-8c49-1d57cf8e59f4;|"IOP00410216:
(COMM_FAILURE) Unable to create IIOP listener on the specified
host/port: 50.50.50.50/3700"
org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 216 completed: No
        at
com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:3187)
        at
com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:3207)
        at
com.sun.corba.ee.impl.transport.SocketOrChannelAcceptorImpl.initialize(SocketOrChannelAcceptorImpl.java:182)

and

Caused by: java.net.BindException: Cannot assign requested address: bind
        at sun.nio.ch.Net.bind(Native Method)
        at
sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:119)
        at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
        at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
        at
com.sun.enterprise.iiop.IIOPSSLSocketFactory.createServerSocket(IIOPSSLSocketFactory.java:301)

I hope things will go smoother for Nicklas with Webservices.

Regards,
Dies


Witold Szczerba wrote:
> 2009/8/16 Dies Koper <diesk_at_fast.au.fujitsu.com>:
>> What do you get if you put your public IP address in the Network Address
>> field, restart your server and run your client again?
>
> Well, if your Glassfish server has address 'x' on network 'y' and your
> client contacts Glassfish using address 'a' on network 'b' which is
> not the address of Glassfish, then what can you do? You cannot lie to
> Glassfish that it's address is 'a' on network 'b' when in fact it's
> address is 'x' on network 'y'. It will fail to start and initialize
> network stack if you lie to it.