You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Jens Wike (JIRA)" <ji...@apache.org> on 2007/12/20 18:06:43 UTC
[jira] Created: (HTTPCLIENT-721) API: HttpException should inherit
from IOException
API: HttpException should inherit from IOException
--------------------------------------------------
Key: HTTPCLIENT-721
URL: https://issues.apache.org/jira/browse/HTTPCLIENT-721
Project: HttpComponents HttpClient
Issue Type: Bug
Affects Versions: 4.0 Alpha 2
Reporter: Jens Wike
The description of IOException reads:
* Signals that an I/O exception of some sort has occurred. This
* class is the general class of exceptions produced by failed or
* interrupted I/O operations.
This means HttpException and its subclasses _is_ an I/O Exception
by the definition above. There is no need to have a separate Exception
hierarchy.
--
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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org
[jira] Resolved: (HTTPCLIENT-721) API: HttpException should inherit
from IOException
Posted by "Roland Weber (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HTTPCLIENT-721?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Roland Weber resolved HTTPCLIENT-721.
-------------------------------------
Resolution: Won't Fix
HttpException is used to indicate protocol errors (server sending invalid data), while IOException is used to indicate communication problems (timeout, server not responding). The two cases have fundamentally different causes and may need different handling, so it is not a good idea to join them into the same exception hierarchy.
Failed parsing of data received from a server certainly isn't a failed IO operation. The IO operation succeeds, it's just the data that cannot be interpreted correctly.
cheers,
Roland
> API: HttpException should inherit from IOException
> --------------------------------------------------
>
> Key: HTTPCLIENT-721
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-721
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Affects Versions: 4.0 Alpha 2
> Reporter: Jens Wike
>
> The description of IOException reads:
> * Signals that an I/O exception of some sort has occurred. This
> * class is the general class of exceptions produced by failed or
> * interrupted I/O operations.
> This means HttpException and its subclasses _is_ an I/O Exception
> by the definition above. There is no need to have a separate Exception
> hierarchy.
--
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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org
[jira] Resolved: (HTTPCLIENT-721) API: HttpException should inherit
from IOException
Posted by "Oleg Kalnichevski (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HTTPCLIENT-721?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Oleg Kalnichevski resolved HTTPCLIENT-721.
------------------------------------------
Resolution: Won't Fix
HttpException has nothing to do with I/O. It is a _protocol_ level exception.
Oleg
> API: HttpException should inherit from IOException
> --------------------------------------------------
>
> Key: HTTPCLIENT-721
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-721
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Affects Versions: 4.0 Alpha 2
> Reporter: Jens Wike
>
> The description of IOException reads:
> * Signals that an I/O exception of some sort has occurred. This
> * class is the general class of exceptions produced by failed or
> * interrupted I/O operations.
> This means HttpException and its subclasses _is_ an I/O Exception
> by the definition above. There is no need to have a separate Exception
> hierarchy.
--
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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org
[jira] Reopened: (HTTPCLIENT-721) API: HttpException should inherit
from IOException
Posted by "Jens Wike (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HTTPCLIENT-721?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jens Wike reopened HTTPCLIENT-721:
----------------------------------
Roland,
> different causes and may need different handling
Of you course you can handle it different also when in the IOException hierarchy, if you
want and can handle it at all.
It is common practice in the Java API to have any I/O related exception under IOException,
examples: java.net.MalformedURLException, java.io.ObjectStreamException, java.util.ZipException.
These have nothing to do with any low-level I/O problems as you mentioned.
Adding additional hierarchies must be avoided, because it leads to a "rethrow pollution"
of the application code.
> API: HttpException should inherit from IOException
> --------------------------------------------------
>
> Key: HTTPCLIENT-721
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-721
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Affects Versions: 4.0 Alpha 2
> Reporter: Jens Wike
>
> The description of IOException reads:
> * Signals that an I/O exception of some sort has occurred. This
> * class is the general class of exceptions produced by failed or
> * interrupted I/O operations.
> This means HttpException and its subclasses _is_ an I/O Exception
> by the definition above. There is no need to have a separate Exception
> hierarchy.
--
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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org
[jira] Issue Comment Edited: (HTTPCLIENT-721) API: HttpException
should inherit from IOException
Posted by "Jens Wike (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HTTPCLIENT-721?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12553734 ]
jwilke edited comment on HTTPCLIENT-721 at 12/20/07 9:47 AM:
----------------------------------------------------------------
Roland,
> different causes and may need different handling
Of you course you can handle it different also when in the IOException hierarchy, if you
want and can handle it at all.
It is common practice in the Java API to have any I/O related exception under IOException,
examples: java.net.MalformedURLException, java.io.ObjectStreamException, java.util.ZipException.
These have nothing to do with any low-level I/O problems as you mentioned.
Adding additional hierarchies must be avoided, because it leads to a "rethrow pollution"
of the application code.
cheers,
jens
was (Author: jwilke):
Roland,
> different causes and may need different handling
Of you course you can handle it different also when in the IOException hierarchy, if you
want and can handle it at all.
It is common practice in the Java API to have any I/O related exception under IOException,
examples: java.net.MalformedURLException, java.io.ObjectStreamException, java.util.ZipException.
These have nothing to do with any low-level I/O problems as you mentioned.
Adding additional hierarchies must be avoided, because it leads to a "rethrow pollution"
of the application code.
> API: HttpException should inherit from IOException
> --------------------------------------------------
>
> Key: HTTPCLIENT-721
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-721
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Affects Versions: 4.0 Alpha 2
> Reporter: Jens Wike
>
> The description of IOException reads:
> * Signals that an I/O exception of some sort has occurred. This
> * class is the general class of exceptions produced by failed or
> * interrupted I/O operations.
> This means HttpException and its subclasses _is_ an I/O Exception
> by the definition above. There is no need to have a separate Exception
> hierarchy.
--
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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org