简体   繁体   中英

What does this exception means

I ran a few test scenarios where I Call SOA Service of a remote system from my SOAP client and came across various remote exceptions. Can you please help me identify what each error signifies:-

1) java.net.ConnectException: Connection refused"

2) java.net.SocketTimeoutException: connect timed out"

3) java.net.ConnectException: Connection timed out"

Can you tell me, which application server are you using ? It seems timeout issue..basically there three types of timeout in web service application..

readTimeout - timeout when service takes more time to respond

writeTimeout - when client takes more time to write onto wire

connectTimeout - initial handshake process takes more time

also post some scenario for each exception

These are generic network communication errors:

1) java.net.ConnectException: Connection refused"

The client has attempted to connect to a server on a particular IP and port. The connection request has made it to the server machine, but there is no service listening for requests on the nominated port. The operating system then "refuses" the connection.

2) java.net.SocketTimeoutException: connect timed out"

The client has attempted to connect to a server, but the server did not respond to the connection request within the allotted time interval.

3) java.net.ConnectException: Connection timed out"

This means the same as the previous exception.

It is likely that 2) and 3) are being handled at different levels in the protocol stack, and that is why the exceptions you are seeing are different. I would need to see stack traces to be sure of that.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM