You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Emīls Šolmanis (JIRA)" <ji...@apache.org> on 2013/06/18 01:15:20 UTC

[jira] [Commented] (HADOOP-8570) Bzip2Codec should accept .bz files too

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

Emīls Šolmanis commented on HADOOP-8570:
----------------------------------------

Hey guys

I'd be willing to do this, which of the approaches though? I think just changing the extension to .bz wouldn't solve this bug 'cause it wouldn't take .bz2 files, which, apart from being this same bug with another extension, would be incompatible.

>From what I see, the changes are contained to {{CompressionCodecFactory}} (and 2 logging statements in {{CodecPool}}). The idea then is to change the {{CompressionCodec}} interface, specifically {{getDefaultExtension()}} and the mechanism pertaining to it to return a set of extensions the codec supports. Also, looks like at the moment there are no checks for extension overlays, so if there are two codecs that report the same extension, one would overwrite another as they get loaded by the {{ServiceLoader}}. I think at the very least this calls for a loud warning in the log, especially if we add this extension aliasing thing.

Your thoughts? Should I go ahead & make a patch for this?
                
> Bzip2Codec should accept .bz files too
> --------------------------------------
>
>                 Key: HADOOP-8570
>                 URL: https://issues.apache.org/jira/browse/HADOOP-8570
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: io
>    Affects Versions: 1.0.0, 2.0.0-alpha
>            Reporter: Harsh J
>              Labels: bzip, newbie
>
> The default extension reported for Bzip2Codec today is ".bz2". This causes it not to pick up .bz files as Bzip2Codec files. Although the extension is not very popular today, it is still mentioned as a valid extension in the bunzip manual and we should support it.
> We should change the Bzip2Codec default extension to "bz", or we should add in a new extension list support to allow for better detection across various aliases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira