[ 
https://issues.apache.org/jira/browse/HADOOP-15612?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16550896#comment-16550896
 ] 

Steve Loughran commented on HADOOP-15612:
-----------------------------------------

Noted. Happy with production code. 
w.r.t testing, I'd use LambdaTestUtils & rethrow the exception if it is wrong, 
as that gives you a stack trace to debug:

{code}
IOException ex = intercept(IOException.class, defaultCodec,
   () -> Compression.Algorithm.LZO.getCodec());
if (!ex.getCause() instanceof ClassNotFoundException) {
  throw ex;
}
{code}

> Improve exception when tfile fails to load LzoCodec 
> ----------------------------------------------------
>
>                 Key: HADOOP-15612
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15612
>             Project: Hadoop Common
>          Issue Type: Improvement
>    Affects Versions: 3.1.0
>            Reporter: Gera Shegalov
>            Assignee: Gera Shegalov
>            Priority: Major
>         Attachments: HADOOP-15612.001.patch, HADOOP-15612.002.patch
>
>
> When hadoop-lzo is not on classpath you get
> {code:java}
> java.io.IOException: LZO codec class not specified. Did you forget to set 
> property io.compression.codec.lzo.class?{code}
> which is probably rarely the real cause given the default class name. The 
> real root cause is not attached to the exception thrown.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to