Sreenath Menon created HIVE-3118:
------------------------------------

             Summary: Automatically invoke .hiverc init script when running 
hiveserver instance. 
                 Key: HIVE-3118
                 URL: https://issues.apache.org/jira/browse/HIVE-3118
             Project: Hive
          Issue Type: Improvement
          Components: Server Infrastructure
            Reporter: Sreenath Menon


Using Hive with Microsoft PowerPivot as visualization tool (connected using 
HiveODBC driver), facing the following problems:

1) Multiple instance of the same set of mapreduce jobs spawned (one after 
another) for a single query.
For eg: select * from tweetsdata;
---------------------------------------------------------------------------
Hive history file=/tmp/hadoop/hive_job_log_hadoop_201206121337_1423188701.txt
Total MapReduce jobs = 2
Launching Job 1 out of 2
Launching Job 2 out of 2
OK
Total MapReduce jobs = 2
Launching Job 1 out of 2
Launching Job 2 out of 2
.
.
//Multiple instance of same MapReduce jobs (with same HDFS read/write values)
---------------------------------------------------------------------------
2)UDF defined before executing the query is not being recognized after the 
first instance of MapReduce jobs (i.e. for instances after this statement which 
says a new instance is started)
Hive history file=/tmp/hadoop/hive_job_log_hadoop_201206121337_1423188701.txt
---------------------------------------------------------------------------
Error:
java.lang.RuntimeException: failed to evaluate: 
<unbound>=Class.forName("retweetlink");
---------------------------------------------------------------------------

So would be a good idea to invoke .hiverc init script for the server instances, 
so that I can define UDF in the .hiverc script and each time of a new instance 
of hiveserver, the script is executed prior to the MapReduce job.

Need this because it cannot be achieved by code repetition as the single query 
(select in this case) is executed across different server instances.
---------------------------------------------------------------------------
add jar /usr/local/hadoop/src/retweetlink1.jar;
create temporary function link as 'retweetlink';
select link(tweet),count(*) as countlink from tweetsdata where tweet like 
'%RT%' group by link(tweet);
---------------------------------------------------------------------------



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to