hadoop-mapreduce-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron Kimball (JIRA)" <j...@apache.org>
Subject [jira] Commented: (MAPREDUCE-923) Sqoop's ORM uses URLDecoder on a file, which replaces plus signs in a jar file name with spaces
Date Wed, 16 Sep 2009 17:17:57 GMT

    [ https://issues.apache.org/jira/browse/MAPREDUCE-923?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756112#action_12756112

Aaron Kimball commented on MAPREDUCE-923:

No tests included: This is a trivial fix, and it's hard to really test this with a unit test
since those are based on {{.class}} files, not jars. The issue comes up when people have a
{{+}} in their jar file name and they can't run Sqoop MapReduce jobs successfully. Testing
just requires that you run any import and make sure it works.

> Sqoop's ORM uses URLDecoder on a file, which replaces plus signs in a jar file name with
> -----------------------------------------------------------------------------------------------
>                 Key: MAPREDUCE-923
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-923
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: contrib/sqoop
>    Affects Versions: 0.20.1
>            Reporter: Kevin Weil
>            Assignee: Aaron Kimball
>         Attachments: MAPREDUCE-923.patch
> In findThisJar, sqoop runs URLDecoder.decode on the resulting jar, which has the effect
of replacing any + signs in the path with a space.  This obviously breaks the classpath variable
that it's trying to set, and the sqoop-generated code fails to compile.  Ironically, Cloudera's
hadoop distro is the one that puts + characters in jar files, and so exhibits the bug.  Here
is an example from running sqoop with log4j at debug level.  Note the space in the very last
term, which should read hadoop-0.20.0+61-sqoop.jar rather than hadoop-0.20.0 61-sqoop.jar.
> 09/08/27 18:00:07 DEBUG orm.CompilationManager: Invoking javac with args: -sourcepath
./ -d /tmp/sqoop/compile/ -classpath /usr/lib/hadoop-0.20/conf:/usr/java/jdk1.6.0_06/lib/tools.jar:/usr/lib/hadoop-0.20:/usr/lib/hadoop-0.20/hadoop-0.20.0+61-core.jar:/usr/lib/hadoop-0.20/lib/commons-cli-2.0-SNAPSHOT.jar:/usr/lib/hadoop-0.20/lib/commons-codec-1.3.jar:/usr/lib/hadoop-0.20/lib/commons-el-1.0.jar:/usr/lib/hadoop-0.20/lib/commons-httpclient-3.0.1.jar:/usr/lib/hadoop-0.20/lib/commons-logging-1.0.4.jar:/usr/lib/hadoop-0.20/lib/commons-logging-api-1.0.4.jar:/usr/lib/hadoop-0.20/lib/commons-net-1.4.1.jar:/usr/lib/hadoop-0.20/lib/core-3.1.1.jar:/usr/lib/hadoop-0.20/lib/hadoop-0.20.0+61-fairscheduler.jar:/usr/lib/hadoop-0.20/lib/hadoop-0.20.0+61-scribe-log4j.jar:/usr/lib/hadoop-0.20/lib/hsqldb-

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

View raw message