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

Hudson commented on SQOOP-3218:
-------------------------------

SUCCESS: Integrated in Jenkins build Sqoop-hadoop200 #1122 (See 
[https://builds.apache.org/job/Sqoop-hadoop200/1122/])
SQOOP-3218: Make sure the original ClassLoader is restored when running (bogi: 
[https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=92e2f999263c0c54b07ab1cde70a0606b277365c])
* (edit) src/java/org/apache/sqoop/mapreduce/hcat/SqoopHCatUtilities.java
* (add) src/test/org/apache/sqoop/mapreduce/hcat/TestSqoopHCatUtilities.java


> Make sure the original ClassLoader is restored when running HCatalog tests
> --------------------------------------------------------------------------
>
>                 Key: SQOOP-3218
>                 URL: https://issues.apache.org/jira/browse/SQOOP-3218
>             Project: Sqoop
>          Issue Type: Improvement
>            Reporter: Szabolcs Vasas
>            Assignee: Szabolcs Vasas
>             Fix For: 1.5
>
>         Attachments: SQOOP-3218.patch
>
>
> When Sqoop runs in test mode it creates another ClassLoader that loads from 
> the generated JAR file in addition to everything else currently on the 
> classpath (see: com.cloudera.sqoop.util.ClassLoaderStack#addJarFile) so it is 
> dependent of Thread.currentThread().getContextClassLoader() value.
> However in HCatalog test cases Sqoop invokes 
> org.apache.hive.hcatalog.cli.HCatCli#main method directly in process 
> (org.apache.sqoop.mapreduce.hcat.SqoopHCatUtilities#executeHCatProgramInProcess)
>  which can override the contextClassLoader in the current thread and cause 
> the tests to fail.
> The task is to improve 
> org.apache.sqoop.mapreduce.hcat.SqoopHCatUtilities#executeHCatProgramInProcess
>  to make sure that the class loader used before invoking HCatCli is restored 
> after the main method of the CLI is finished.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to