james-mime4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <mime4j-...@james.apache.org>
Subject [jira] Commented: (MIME4J-137) Rewrite MimeIOException eliminate unecessary MimeException and provide general constructors
Date Wed, 10 Jun 2009 08:07:07 GMT

    [ https://issues.apache.org/jira/browse/MIME4J-137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12717977#action_12717977
] 

Oleg Kalnichevski commented on MIME4J-137:
------------------------------------------

> What would be the use case for catching a MimeIOException and then throwing MimeException?

In short, exception handling and error recovery. 

IOExceptions are meant to represent transport errors, potentially recoverable, whereas MimeExceptions
are meant to represent protocol, potentially fatal. I personally consider such distinction
quite important. There are situations when protocol errors can only be signaled by throwing
an exception derived from IOException class. In this case it makes sense to rethrow MimeIOException
as MimeException at a higher level.

Oleg

> Rewrite MimeIOException eliminate unecessary MimeException and provide general constructors
> -------------------------------------------------------------------------------------------
>
>                 Key: MIME4J-137
>                 URL: https://issues.apache.org/jira/browse/MIME4J-137
>             Project: JAMES Mime4j
>          Issue Type: Improvement
>    Affects Versions: 0.6
>            Reporter: Nathan Beyer
>            Priority: Minor
>             Fix For: 0.7
>
>         Attachments: MimeIOException.patch
>
>
> Rewrite the MimeIOException class to eliminate the hidden construction of a MimeException
and provide a more conventional set of constructors.

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


Mime
View raw message