Philip: hive> add jar hdfs://localhost/FooTest.jar; Unable to validate hdfs://localhost/FooTest.jar Exception: Call to localhost/127.0.0.1:8020 failed on connection exception: java.net.ConnectException: Connection refused
Do you know how the port (8020) is configured for 'add jar' command ? Thanks On Sat, Mar 27, 2010 at 9:04 PM, Philip Zeyliger (JIRA) <j...@apache.org>wrote: > > [ > https://issues.apache.org/jira/browse/HIVE-1157?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12850628#action_12850628] > > Philip Zeyliger commented on HIVE-1157: > --------------------------------------- > > Edward, > > I'm having trouble reproducing the error you're seeing. > > {quote} > > create temporary function geoip as > 'com.jointhegrid.hive.udf.GenericUDFGeoIP'; > > hive> select geoip(theIp ,'COUNTRY_NAME', './GeoLiteCity.dat.gz' ) from ip > ; > java.lang.ClassNotFoundException: com.jointhegrid.hive.udf.GenericUDFGeoIP > Continuing ... > {quote} > > On my machine, if I create temporary function with a class name that > doesn't exist, it fails. So it makes no sense to me that "create temporary > function" is succeeding, but then it's immediately not finding it. Do you > have any theories on what's going on? Can you try to run it with debug on? > > Thanks! > > > UDFs can't be loaded via "add jar" when jar is on HDFS > > ------------------------------------------------------ > > > > Key: HIVE-1157 > > URL: https://issues.apache.org/jira/browse/HIVE-1157 > > Project: Hadoop Hive > > Issue Type: Improvement > > Components: Query Processor > > Reporter: Philip Zeyliger > > Priority: Minor > > Attachments: hive-1157.patch.txt, HIVE-1157.patch.v3.txt, > HIVE-1157.v2.patch.txt, output.txt > > > > > > As discussed on the mailing list, it would be nice if you could use UDFs > that are on jars on HDFS. The proposed implementation would be for "add > jar" to recognize that the target file is on HDFS, copy it locally, and load > it into the classpath. > > {quote} > > Hi folks, > > I have a quick question about UDF support in Hive. I'm on the 0.5 > branch. Can you use a UDF where the jar which contains the function is on > HDFS, and not on the local filesystem. Specifically, the following does not > seem to work: > > # This is Hive 0.5, from svn > > $bin/hive > > Hive history > file=/tmp/philip/hive_job_log_philip_201002081541_370227273.txt > > hive> add jar hdfs://localhost/FooTest.jar; > > Added hdfs://localhost/FooTest.jar to class path > > hive> create temporary function cube as 'com.cloudera.FooTestUDF'; > > FAILED: Execution Error, return code 1 from > org.apache.hadoop.hive.ql.exec.FunctionTask > > Does this work for other people? I could probably fix it by changing > "add jar" to download remote jars locally, when necessary (to load them into > the classpath), or update URLClassLoader (or whatever is underneath there) > to read directly from HDFS, which seems a bit more fragile. But I wanted to > make sure that my interpretation of what's going on is right before I have > at it. > > Thanks, > > -- Philip > > {quote} > > {quote} > > Yes that's correct. I prefer to download the jars in "add jar". > > Zheng > > {quote} > > -- > This message is automatically generated by JIRA. > - > You can reply to this email to add a comment to the issue online. > >