kettle執(zhí)行定時任務kitchen.bat該如何分析-創(chuàng)新互聯(lián)

今天就跟大家聊聊有關(guān)kettle執(zhí)行定時任務kitchen.bat該如何分析,可能很多人都不太了解,為了讓大家更加了解,小編給大家總結(jié)了以下內(nèi)容,希望大家根據(jù)這篇文章可以有所收獲。

專注于為中小企業(yè)提供網(wǎng)站制作、成都網(wǎng)站設計服務,電腦端+手機端+微信端的三站合一,更高效的管理,為中小企業(yè)商水免費做網(wǎng)站提供優(yōu)質(zhì)的服務。我們立足成都,凝聚了一批互聯(lián)網(wǎng)行業(yè)人才,有力地推動了1000多家企業(yè)的穩(wěn)健成長,幫助中小企業(yè)通過網(wǎng)站建設實現(xiàn)規(guī)模擴充和轉(zhuǎn)變。

環(huán)境
操作系統(tǒng):windows server 2008_x86
etl:kettle6.0

Kettle是一個開源的ETL(Extract-Transform-Load的縮寫,即數(shù)據(jù)抽取、轉(zhuǎn)換、裝載的過程)項目,項目名很有意思,水壺。按項目負責人Matt的說法:把各種數(shù)據(jù)放到一個壺里,然后呢,以一種你希望的格式流出。Kettle包括三大塊:

Spoon——轉(zhuǎn)換/工作(transform/job)設計工具 (GUI方式)
Kitchen——工作(job)執(zhí)行器 (命令行方式)
Span——轉(zhuǎn)換(trasform)執(zhí)行器 (命令行方式)

Kettle是一款國外開源的etl工具,純java編寫,綠色無需安裝,數(shù)據(jù)抽取高效穩(wěn)定。Kettle中有兩種腳本文件,transformation和job,transformation完成針對數(shù)據(jù)的基礎轉(zhuǎn)換,job則完成整個工作流的控制。

kitchen.bat后面可以是-也可以是/ 然后加上options
Options:
  /rep            : Repository name 資料庫名稱
  /user           : Repository username 資料庫用戶名
  /pass           : Repository password 資料庫密碼
  /job            : The name of the job to launch  job名
  /dir            : The directory (dont forget the leading /) job的目錄
  /file           : The filename (Job XML) to launch  xml job的文件名
  /level          : The logging level (Basic, Detailed, Debug, Rowlevel, Error, Nothing) 日志級別
  /logfile        : The logging file to write to 日志文件名
  /listdir        : List the directories in the repository 列出在檔案庫的目錄
  /listjobs       : List the jobs in the specified directory 列出在特定目錄下的job
  /listrep        : List the available repositories 列出可用的檔案庫
  /norep          : Do not log into the repository 不登陸檔案庫
  /version        : show the version, revision and build date 查看版本及創(chuàng)建日期
  /param          : Set a named parameter <NAME>=<VALUE>. For example -param:FILE=customers.csv
  /listparam      : List information concerning the defined parameters in the specified job.
  /export         : Exports all linked resources of the specified job. The argument is the name of a ZIP file.
  /custom         : Set a custom plugin specific option as a String value in the job using <NAME>=<Value>, for example: -custom:COLOR=Red
  /maxloglines    : The maximum number of log lines that are kept internally by Kettle. Set to 0 to keep all rows (default)
  /maxlogtimeout  : The maximum age (in minutes) of a log line while being kept internally by Kettle. Set to 0 to keep all rows indefinitely (default)


編寫一個test_job.bat 內(nèi)容如下:
D:
cd D:\Program Files\kettle\data-integration
kitchen.bat -rep kettlerep -user admin -pass admin -dir  /job_dir  -job job_name  -level=basic>D:\JOB_LOG\job_input.log
-rep kettlerep 指定資料檔案庫名稱
-user admin -pass admin 用戶名,密碼
-dir  /job_dir 指定目錄
-job job_name 設置job名稱
-level=basic>D:\JOB_LOG\job_input.log設置日志級別及輸出路徑。

pan.bat 
Options:
  /rep            : 資源庫名稱
  /user          : 資源庫用戶名
  /pass          : 資源庫密碼
  /trans          : 要啟動的轉(zhuǎn)換名稱
  /dir            : 目錄(不要忘了前綴 /)
  /file           : 要啟動的文件名(轉(zhuǎn)換所在的 XML 文件)
  /level         : 日志等級 (基本, 詳細, 調(diào)試, 行級, 錯誤, 沒有)
  /logfile       : 要寫入的日志文件
  /listdir        : 列出資源庫里的目錄
  /listtrans    : 列出指定目錄下的轉(zhuǎn)換
  /listrep       : 列出可用資源庫
  /exprep      : 將資源庫里的所有對象導出到 XML 文件中
  /norep        : 不要將日志寫到資源庫中
  /safemode       : 安全模式下運行: 有額外的檢查
  /version        : 顯示版本,校訂和構(gòu)建日期
  /param         : Set a named parameter <NAME>=<VALUE>. For example -param:FOO=bar
  /listparam     : List information concerning the defined named parameters in the specified transformation.
  /metrics        : Gather metrics during execution
  /maxloglines    : The maximum number of log lines that are kept internally by Kettle. Set to 0 to keep all rows (default)
  /maxlogtimeout  : The maximum age (in minutes) of a log line while being kept internally by Kettle. Set to 0 to keep all rows indefinitely (default)

看完上述內(nèi)容,你們對kettle執(zhí)行定時任務kitchen.bat該如何分析有進一步的了解嗎?如果還想了解更多知識或者相關(guān)內(nèi)容,請關(guān)注創(chuàng)新互聯(lián)-成都網(wǎng)站建設公司行業(yè)資訊頻道,感謝大家的支持。

網(wǎng)站題目:kettle執(zhí)行定時任務kitchen.bat該如何分析-創(chuàng)新互聯(lián)
標題路徑:http://muchs.cn/article14/sppde.html

成都網(wǎng)站建設公司_創(chuàng)新互聯(lián),為您提供網(wǎng)站建設、企業(yè)網(wǎng)站制作、商城網(wǎng)站、品牌網(wǎng)站設計、靜態(tài)網(wǎng)站網(wǎng)站策劃

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

成都網(wǎng)站建設公司