You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sqoop.apache.org by "Abraham Fine (JIRA)" <ji...@apache.org> on 2015/10/05 21:55:26 UTC

[jira] [Updated] (SQOOP-2602) Sqoop2: Static initialization of ClassUtils defaultClassloader is fragile

     [ https://issues.apache.org/jira/browse/SQOOP-2602?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Abraham Fine updated SQOOP-2602:
--------------------------------
    Attachment: SQOOP-2602.patch

> Sqoop2: Static initialization of ClassUtils defaultClassloader is fragile
> -------------------------------------------------------------------------
>
>                 Key: SQOOP-2602
>                 URL: https://issues.apache.org/jira/browse/SQOOP-2602
>             Project: Sqoop
>          Issue Type: Bug
>    Affects Versions: 1.99.6
>            Reporter: Abraham Fine
>         Attachments: SQOOP-2602.patch
>
>
> While working with [~jarcec] on SQOOP-2490 we discovered an issue relating to the way that {{ClassUtils}} reads the current class loader from the thread. In an integration testing use case, we may want to append a new jar to the classpath (or remove jars) between tests. 
> Currently, the {{defaultClassloader}} for {{ClassUtils}} is set in a {{static}} block, this means that, should the connectors that are being used change between tests, {{ClassUtils}} will be unable to reflect this change. We should change {{defaultClassloader}} to a method that reads the class loader from the thread each time that it is called.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)