Java客户端服务器怀疑

问题描述:

大家好,

我是Java的新手,并且开发了一个客户端服务器应用程序,该应用程序在本机上可以正常运行,即我通过使用回送地址127.0.0.1在本机上运行服务器,但是该服务器实际上将在IP地址为的计算机上运行美国和客户将在印度,无论我的程序是否运行,我都感到不安,请与我分享您的经验.

感谢ADVANCE

Hi All,

I am new to java and developed a client server application which is working fine on my local machine ie i am running server on my machine by using loop back address 127.0.0.1, but the server actually will run on a machine with a IP address in USA and client will be in INDIA i am having some anxiety whether my programm will run or not, Please share your experience with me.

THANKS IN ADVANCE

无论服务器套接字通过TCP可以从客户端访问什么地方,您都不会有问题(除非网络崩溃,但只有Chuck Norris可以避免它) ;)).
最常见的错误是使服务器应用程序在动态IP路由器后面运行,每次重置路由器时,都会有一个用于连接的新IP;因此最好的选择是使用动态域名服务(DNS)解析器作为几乎所有路由器(例如www.dyndns.org)上的集成服务与路由器一起使用,以便您的客户端将始终指向服务器套接字.已重设.
如果您需要更多信息,请询问!!!!

祝你好运!
You won''t have problem wherever the server socket be accesible from your client over TCP (unless network falldown, but only Chuck Norris can avoid it ;) ).
The most common error is to make server app work behind a Dynamic IP router, each time the router is resetted there''s a new IP for your connection; so the best option is to use a dynamic Domain Name Service (DNS) solver usable with your router as an integrated service on almost all routers, for example www.dyndns.org, so your client will point allways to your server socket whenever it be resetted.
If you need more info, please ask it !!!!

Good Luck !