On 18-07-11 14:07, Peter Firmstone wrote:
Sim IJskes - QCG wrote:
On 10-07-11 06:37, Peter wrote:
Any suggestions, ideas or assistance is welcome.

A ServerEndpoint needs to know its external contact identity. In case
of the TcpServerEndpoint the hostname where the client needs to
connect to.

Correct, that would be the publicly visible address and port.


A ServerEndpoint behind a NAT probably has a private net address/
hostname.

Correct, clients on the net need a public address.



Where do you connect to the proxy server to fetch the external address?

It would require a custom ServerSocketFactory, so that when a Service is
exported using a ServerEndpoint, during the export process, a port is

If you take a look at TcpServerEndpoint.enumerateListenEndpoints where the TcpEndpoint is created (or fetched) for export, where it is serialized. You will see there that the endpoint description consists of host, port and socketFactory.

In the TcpEndpoint this will be used to create the socket. The socket will be created with the sf.createSocket() call, and after creation the socket.connect(socketAddress, timeout); will be called.

This socketAddress will always be a InetSocketAddress. Do you see opportunities to do some translation or lookup in there?

Gr. Sim

--
QCG, Software voor het MKB, 071-5890970, http://www.qcg.nl
Quality Consultancy Group b.v., Leiderdorp, Kvk Den Haag: 28088397

Reply via email to