WebService: Firefox cannot establish a connection to the server at 192.168.10.203:8080

I am trying to create a WebService. I can not access the url. If I try to connect to

http://192.168.10.203:8080/EchoBeanService/EchoBean?wsdl

I get an error message:

Firefox can't establish a connection to the server at 192.168.10.203:8080

However, if I can connect to using localhost in the url:

http://localhost:8080/EchoBeanService/EchoBean?wsdl 

Echo.java

package services;

public interface Echo {
    public String printEcho();
    public String printEchoParam(String str);

}

EchoBean.java   batch model;

import javax.jws.WebService;
import javax.ejb.Stateless;
import javax.jws.WebMethod;
import services.Echo;

@Stateless
@WebService
public class EchoBean implements Echo {
public EchoBean(){}
@WebMethod
    public String printEcho(){
        return "WebServices Echo ";
    }
@WebMethod
    public String printEchoParam(String str){
        return ("In PrintEcho( String " + str +" )" );
    }
}

-H

+3
source share
6 answers

Thanks everyone

Fixed issue by reinstalling my server from saltwater fish.

0
source

java, - . , - java- , localhost: 8080? , : URL -?

, " -": http://today.java.net/article/2006/06/12/web-services-made-easy-jax-ws-20

, , : , , IP-, , .

+1

:

  • 192.168.10.203 IP-?
  • - ( 192.168.10.203), ?
0

. , .

, telnet .

telnet 192.168.10.203 8080
0

Linux, IPTABLE. , IP/Hostname.

IP-. IP- ifconfig ( unix) ipconfig (win)

0
source

If this is a home network, I know that some routers / modems do not like to return to themselves (I saw this behavior with Linksys devices). But localhost still works, because the OS catches it before it goes to the network device. Have you tried connecting to other ports on your computer or just ping IP addresses to see if it is responding?

0
source

Source: https://habr.com/ru/post/1747266/


All Articles