网络服务器访问
这可能是网络中的一个基本问题,但我因此陷入困境。 我有一个 REST Web 服务,部署在装有 Windows XP 的计算机上。我可以使用同一台计算机上的 localhost:8080 uri 访问它。但现在我想从局域网中的其他机器上使用它。如果我从其他机器上 ping 到我的机器,我就可以访问它。我可以从其他机器上看到我机器的 ipaddress:8080 url。在部署在其他机器 glassfish 上的客户端中,我尝试使用 url 中的 IP 地址或计算机名称访问我的 Web 服务,但我看不到两台机器之间的任何通信(我正在查看网络服务机)。请告诉我如何配置单个 glassfish 以满足局域网中的所有机器的需求。 任何帮助/建议表示赞赏!
This probably is an elementary question in networking but I am stuck due to it.
I have a rest web service I have deployed on a machine with windows xp. I can access it using localhost:8080 uri from the same machine. But now I want to use it from the other machines in my LAN. If I ping to my chine from other machines I can access it. I can see the ipaddress:8080 url of my machine from other machines. In my client which is deployed on the other machines glassfish, I am trying to access my web service with the ip address or the computer name in the url but i cannot see any communication between both machines( I am watching the server.log of the webservice machine). Please tell me how do I configure the single glassfish to cater to all machines in the lan.
Any help/ suggestion is appreciated!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否收到有关该问题的具体错误消息?
您需要进行一些网络诊断。尝试 telnet 或 putty 查看端口是否可以从一台计算机到达另一台计算机。基本上,如果能够无错误地连接,那就很好了。 Putty 会立即关闭,但它至少会证明端口是可以访问的。您可能有防火墙阻止它或其他一些网络问题。
Do you get a specific error message about the problem?
You need to do some networking diagnostics. Try telnet or putty to see if the port is reachable from one machine to the other. Basically if you can connect without an error, it's good. Putty will just close right away, but it will at least prove the port is reachable. You might have a firewall blocking it or some other networking trouble.
问题出在 javascript 上。
由于 javascript 错误不会生成特定错误,因此我对所有代码进行了注释,然后一次删除一行注释以查找语法错误。
当错误在 javascript 中解决后,它会一直持续到 ajax 调用。直到那时,整个 javascript 函数都处于未定义状态!
想知道如何在 javascript 中捕获此类编码错误。我只能在服务器计算机上使用 firebug 进行调试。
谢谢
The problem was with javascript.
Since no specific error is generated for javascript errors, i commented all code and then removed comment one line at a time to find the syntax error.
When the error was resolved in javascript it went till the ajax call. Untill then nothing as the entire javascript function comes under undefined!!
Wonder how to trap such coding errors in javascript. I can use firebug for debuging only on the server machine.
Thanks