[英]Accessing Hive queries from Jenkins
I am planning to use Jenkins with Hive. 我计划将Jenkins与Hive一起使用。 I have created some Hive scripts: test1.hql, test2.hql, test3.hql which lie on the sample server "ssh rt@test1.test2.net" location "/home/rt"
我创建了一些Hive脚本:test1.hql,test2.hql,test3.hql,它们位于示例服务器“ ssh rt@test1.test2.net”上的位置“ / home / rt”
test1.hql:
select id, name from tblA;
test2.hql:
select id, name from tblB;
test3.hql:
select id, name from tblC;
How can I execute it from Jenkins? 我如何从詹金斯执行它?
On Jenkins up-to below is what I did: 在詹金斯上,我所做的是:
New Job > Job name as test > Build a free-style software project 新工作>测试的工作名称>建立自由风格的软件项目
How can I point to my .hql scripts from Jenkins and what settings do I need to have? 如何指向Jenkins的.hql脚本,我需要进行哪些设置? I am new to Jenkins.
我是詹金斯的新手。
Any help? 有什么帮助吗?
Thanks. 谢谢。
Found something: 发现了一些东西:
Create a Jenkins job In the configuration of that job there is a "Build" section with "Add build step" Add a "Execute Shell" step, and put your code. 创建Jenkins作业在该作业的配置中,具有“构建”部分的“添加构建步骤”和“执行Shell”步骤,然后放入您的代码。
that code would be basically: hive -f /pathtohql/test1.hql 该代码基本上是:hive -f /pathtohql/test1.hql
The only issue i see with this is that the m/c with jenkins will have to have hive installed and pointing to the correct metastore & cluster. 我看到的唯一问题是,带有jenkins的m / c必须安装蜂巢并指向正确的metastore和集群。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.