如何在Pentaho BI服务器v6 CE上部署计划的Kettle作业 [英] How to deploy scheduled Kettle jobs on Pentaho BI server v6 CE

查看:109
本文介绍了如何在Pentaho BI服务器v6 CE上部署计划的Kettle作业的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一台运行Pentaho BI服务器v6社区版的服务器.我们已经开发了Kettle作业,可以从一个数据库提取到另一个数据库,并作为KJB文件导出.我想每12个小时左右执行一次这项工作.

I have a server running Pentaho BI server v6 Community Edition. We've developed a Kettle job to extract from one database to another, exported as a KJB file. I would like to run this job every 12 or so hours.

我注意到BI服务器已经包含Kettle,并且具有上载和计划作业的能力.如果BI服务器已经安装了Kettle,我是否需要安装DI服务器?

I noticed that the BI server already included Kettle, and has the ability to upload and schedule jobs. Do I need to install the DI server if the BI server already has Kettle installed?

如果没有,如何将KJB文件发布到BI服务器?我想使用文件系统存储库.如果我直接通过用户控制台上传文件,日志将显示导入成功,但是我无法在任何地方选择或运行该作业.

If not, how can I publish the KJB file into the BI server? I'd like to use a file system repository. If I upload the file directly through the user console the log shows that the import was a success, but I cannot select or run the job anywhere.

推荐答案

我使用Pentaho BI服务器5,但在Pentaho BI 6上应该可以正常使用.

I use Pentaho BI server 5, but it should work same on Pentaho BI 6.

我的水壶工作运行许多子转换.转换文件存储在文件系统目录中,例如/opt/etl.

My Kettle job runs many sub-transformations. Transformation files are stored on file system directory e.g. /opt/etl.

所以可以说我有一份工作(daily_job.kjb),其中有两个子转换.

So lets say I have one job (daily_job.kjb) with two sub-transformations.

要在Pentaho BI CE上运行Kettle job,请执行以下步骤:

To run a Kettle job on Pentaho BI CE I use those steps:

  1. 在作业文件中正确设置转换位置
  2. 将子转换上传到服务器(/opt/etl)上的正确目录
  3. 创建在BI服务器(daily.xaction)上执行Kettle jobxaction文件
  4. daily.xactiondaily_job.kjb文件上传到Pentaho BI服务器(相同的文件夹)
  5. Pentaho BI服务器上的
  6. 计划daily.xaction文件
  1. set up a transformation location properly in job file
  2. upload sub-transformations to proper directory on server (/opt/etl)
  3. create xaction file which executes Kettle job on BI server (daily.xaction)
  4. upload daily.xaction and daily_job.kjb files to Pentaho BI server (same folder)
  5. schedule daily.xaction file on Pentaho BI server

daily_job.kjb 中的作业设置:

Job settings in daily_job.kjb:

Xaction代码daily.xaction (仅执行与xaction所在位置相同的BI服务器中相同文件夹中的daily_job.kjb):

Xaction code daily.xaction (simply it executes daily_job.kjb located in same folder in BI server as where xaction is):

<?xml version="1.0" encoding="UTF-8"?>
<action-sequence> 
  <title>My scheduled job</title>
  <version>1</version>
  <logging-level>ERROR</logging-level>
  <documentation> 
    <author>mzy</author>  
    <description>Sequence for running daily job.</description>  
    <help/>  
    <result-type/>  
    <icon/> 
  </documentation>

  <inputs> 
  </inputs>

  <outputs> 
    <logResult type="string">
      <destinations>
        <response>content</response>
      </destinations>
    </logResult>
  </outputs>

  <resources>
    <job-file>
      <solution-file> 
        <location>daily_job.kjb</location>  
        <mime-type>text/xml</mime-type> 
      </solution-file>     
    </job-file>
  </resources>

  <actions> 
    <action-definition>
      <component-name>KettleComponent</component-name>
      <action-type>Pentaho Data Integration Job</action-type>
      <action-inputs>   
      </action-inputs>
      <action-resources>
        <job-file type="resource"/>
      </action-resources>
      <action-outputs> 
        <kettle-execution-log type="string" mapping="logResult"/>  
        <kettle-execution-status type="string" mapping="statusResult"/> 
      </action-outputs>   
      <component-definition>
        <kettle-logging-level><![CDATA[info]]></kettle-logging-level>           
      </component-definition>
    </action-definition>

  </actions> 
</action-sequence>

在Pentaho BI CE上计划水壶作业(xaction文件):

这篇关于如何在Pentaho BI服务器v6 CE上部署计划的Kettle作业的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆