You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Ortwin Glück (JIRA)" <ji...@apache.org> on 2007/10/24 09:37:50 UTC

[jira] Commented: (HTTPCLIENT-697) Http Client give sme message when proxy/http endpoint is down

    [ https://issues.apache.org/jira/browse/HTTPCLIENT-697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12537225 ] 

Ortwin Glück commented on HTTPCLIENT-697:
-----------------------------------------

We could subclass java.net.ConnectException and add some fields like the HostConfiguration. Then catch, wrap, throw. If you're esoteric, you may argue that this change may break existing users that serialize the exception and lack the class on the deserializing side. Not sure if we should change that in 3.x.

> Http Client give sme message when proxy/http endpoint is down
> -------------------------------------------------------------
>
>                 Key: HTTPCLIENT-697
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-697
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient
>    Affects Versions: 3.1 Final
>            Reporter: Pankaj
>            Priority: Minor
>
> Whether Http sever endpoint is down or the proxy server is down we get the same stack trace as:
> java.net.ConnectException: Connection refused
> 	at java.net.PlainSocketImpl.socketConnect(Native Method)
> 	at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
> 	at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
> 	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
> 	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
> 	at java.net.Socket.connect(Socket.java:518)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at org.apache.commons.httpclient.protocol.ReflectionSocketFactory.createSocket(ReflectionSocketFactory.java:139)
> 	at org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:124)
> 	at org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:706)
> 	at org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.open(MultiThreadedHttpConnectionManager.java:1321)
> 	at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:386)
> 	at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:170)
> 	at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:396)
> 	at com.approuter.module.http.protocol.HttpTransportSender.perform(HttpTransportSender.java:214)
> 	at 
> It will be good if we can get information whether the proxy was down or the Http endpoint.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org