hadoop-hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zheng Shao (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HIVE-574) Hive should use ClassLoader from hadoop Configuration
Date Fri, 26 Jun 2009 03:24:07 GMT

    [ https://issues.apache.org/jira/browse/HIVE-574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12724372#action_12724372

Zheng Shao commented on HIVE-574:

I was trying to make the changes and found some other problems.

The SessionState is only available in ql, while JavaUtils is in common right now. SessionState
depends on a bunch of Hive ql classes so I cannot move it to common, and JavaUtils is called
from serde, metastore, and ql.

I will change both serde and metastore methods to require hadoop configuration, so that they
can get the classloader from it.

I will also move JavaUtils to ql.

> Hive should use ClassLoader from hadoop Configuration
> -----------------------------------------------------
>                 Key: HIVE-574
>                 URL: https://issues.apache.org/jira/browse/HIVE-574
>             Project: Hadoop Hive
>          Issue Type: Bug
>    Affects Versions: 0.3.0, 0.3.1
>            Reporter: Zheng Shao
>            Assignee: Zheng Shao
>         Attachments: HIVE-574.1.patch, HIVE-574.2.patch, HIVE-574.3.patch
> See HIVE-338.
> Hive should always use the getClassByName method from hadoop Configuration, so that we
choose the correct ClassLoader. Examples include all plug-in interfaces, including UDF/GenericUDF/UDAF,
SerDe, and FileFormats. Basically the following code snippet shows the idea:
> {code}
> package org.apache.hadoop.conf;
> public class Configuration implements Iterable<Map.Entry<String,String>>
>    ...
>   /**
>    * Load a class by name.
>    * 
>    * @param name the class name.
>    * @return the class object.
>    * @throws ClassNotFoundException if the class is not found.
>    */
>   public Class<?> getClassByName(String name) throws ClassNotFoundException {
>     return Class.forName(name, true, classLoader);
>   }
> {code}

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

View raw message