[
https://issues.apache.org/jira/browse/HIVE-1265?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12872996#action_12872996
]
Edward Capriolo commented on HIVE-1265:
---------------------------------------
{noformat}
public static List<Class> getClassesForPackage(String packageName, Class
classType){
+ List<Class> matchingClasses = new ArrayList<Class>();
+ File directory = null;
+ System.out.println(packageName.replace('.', File.separatorChar));
+ URL u = Thread.currentThread().getContextClassLoader()
+ //URL u = new Object().getClass().c
+ .getResource(packageName.replace('.', File.separatorChar));
{noformat}
It seems like this section of code only picks up classes in
ql/test/org.apache.hadoop.hive.ql.udf. This must have something to do with
classloaders/threads/ and getResource(). It seems like getResource is unaware
that two folders could be responsible for the same resource. Or I have to find
a better way to do this.
> Function Registry should should auto-detect UDFs from UDF Description
> ----------------------------------------------------------------------
>
> Key: HIVE-1265
> URL: https://issues.apache.org/jira/browse/HIVE-1265
> Project: Hadoop Hive
> Issue Type: Improvement
> Reporter: Edward Capriolo
> Assignee: Edward Capriolo
> Attachments: hive-1265-patch.diff
>
>
> We should be able to register functions dynamically.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.