Embulk¶
About¶
Treasure Data社発のOSSで、プラガブルなETLフレームワーク的なソフトウェア。
Documentation: https://www.embulk.org/docs/
Spec¶
- 内部に独自データ型を持っているようで、Inputプラグインから受け取る際に一度変換が起こる
Configuration¶
- YAMLまたはLiquidテンプレート。
Liquidテンプレート¶
https://www.embulk.org/docs/built-in.html#using-variables
重要:
- Liquidテンプレートを使う場合、 拡張子は必ず
.yml.liquidにしなければならない
機能:
- 環境変数の利用。例:
{{ env.ENV_KEY }} - include
フォーマット¶
in: # Input plugin
paraser: # Parser plugin
decoder: # Decoder plugin
out: # Output plugin
formatter: # Formatter plugin
encoder: # Encoder plugin
filters: # Filter plugin
exec: # Executor plugin
CLI¶
| Option | 値 | 機能 |
|---|---|---|
-l, --log-level LEVEL |
trace,debug,info,warn,error | ログレベル |
Troubles¶
遭遇したエラーなどについて書く。
個別のプラグインの問題はPluginsに記す。
全体的にエラーがわかりづらいと思う。
参考:
Setting null to a task field is not allowed¶
例:
Error: org.embulk.config.ConfigException: com.fasterxml.jackson.databind. \
JsonMappingException: Setting null to a task field is not allowed. Use Optional<T> \
(com.google.common.base.Optional) to represent null.
どうも、configの設定値が取れなかったときに起こるエラーっぽい。
よくあるのは、環境変数の設定ミス(一度やらかした)。
- キーが間違っていないか
- exportしているか
などを確認するとよさそう。
A Buffer detected double release() calls¶
2020年7月、MySQL -> BigQueryへのETL操作をAWS ECS Fargate上で実行しているときに、50GB以上の大きなテーブルで起こった。
今のところ、ECS Taskのストレージ不足なのでは、という気がしている。
Fargateのエフェメラルストレージは20GB程度しかないようなので。
ありがとうございます。Errno::ENOSPCって出ているから、中間データを書き込むためのディスク容量が足りないってことはないですか?
— Hiroyuki Sato (@hiroysato) July 10, 2020
参考: