sqoop-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SQOOP-1227) Sqoop fails to compile against commons-io higher then 1.4
Date Wed, 06 Nov 2013 02:18:18 GMT

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

Hudson commented on SQOOP-1227:
-------------------------------

SUCCESS: Integrated in Sqoop-ant-jdk-1.6-hadoop200 #866 (See [https://builds.apache.org/job/Sqoop-ant-jdk-1.6-hadoop200/866/])
SQOOP-1227. Sqoop fails to compile against commons-io higher then 1.4 (hshreedharan: https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=bbc2c17a77cb17b195f465d9ab15d45f2b39c6b1)
* src/java/org/apache/sqoop/mapreduce/DataDrivenImportJob.java


> Sqoop fails to compile against commons-io higher then 1.4
> ---------------------------------------------------------
>
>                 Key: SQOOP-1227
>                 URL: https://issues.apache.org/jira/browse/SQOOP-1227
>             Project: Sqoop
>          Issue Type: Bug
>    Affects Versions: 1.4.4
>            Reporter: Jarek Jarcec Cecho
>            Assignee: Jarek Jarcec Cecho
>             Fix For: 1.4.5
>
>         Attachments: SQOOP-1227.patch
>
>
> The problem is in [DataDrivenImportJob.writeAvroSchema|https://github.com/apache/sqoop/blob/trunk/src/java/org/apache/sqoop/mapreduce/DataDrivenImportJob.java#L103]
where we have following code fragment:
> {code}
>     FileUtils.writeStringToFile(schemaFile, schema.toString(true), null);
> {code}
> The last parameter to the function call is {{null}} without any type. This works fine
in {{commons-io}} 1.4 as the method {{writeStringToFile}} have only two different definitions:
> {code}
> writeStringToFile(File file, String data) 
> writeStringToFile(File file, String data, String encoding) 
> {code}
> However later versions has added a lot of other definitions, such as:
> {code}
> writeStringToFile(File file, String data, Charset encoding)
> {code}
> And thus the compilation fails on ambiguity problem:
> {code}
>     [javac] /home/jarcec/apache/repos/sqoop/src/java/org/apache/sqoop/mapreduce/DataDrivenImportJob.java:109:
error: reference to writeStringToFile is ambiguous, both method writeStringToFile(File,String,Charset)
in FileUtils and method writeStringToFile(File,String,String) in FileUtils match
>     [javac]     FileUtils.writeStringToFile(schemaFile, schema.toString(true), null);
>     [javac]              ^
> {code}



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message