Embulkã®executor pluginã®ä»çµã¿ã¨ãããã¯ã¼ã¯ããã°ã©ãã³ã°ãå¦ã³ããã£ãã®ã§ãåå¼·ãã¦ããã®ãããªãã©ã°ã¤ã³ãä½ã£ã¦ã¿ã¾ããã
ã§ãããã¨
- Embulkã®ã¿ã¹ã¯ã®å®è¡ãå¥ã«ç«ã¦ãå°ç¨ã®ãµã¼ã(以ä¸
Embulkãµã¼ã
ã¨å¼ã³ã¾ã)ä¸ã§å®è¡ã§ãã - è¤æ°ãµã¼ãã«ã¿ã¹ã¯ã®å¦çãåæ£ããã
- ãµã¼ãã¨ã®æ¥ç¶ãåããã¨ãã«åæ¥ç¶ãã
ã§ããªãã㨠(TODOs)
- Maven style pluginãå®è¡ãã (å®è¡ã§ããã®ã¯Gemã®ãã©ã°ã¤ã³ã®ã¿) *1
- LocalExecutorã®scatter modeã®ããã«ï¼ã¤ã®Inputãè¤æ°ã®ã¢ã¦ããããã«åãã (inã¨outã1:1ã«ç´ä»ã)
- è¤æ°ãã¼ã¸ã§ã³ã®Embulkã使ã(ãµã¼ãã«çµã¿è¾¼ã¾ãã¦ããEmbulk0.9.16ãåºå®ã§ä½¿ç¨)
- ã»ãã¥ã¢ãªä»çµã¿
TLSæ¥ç¶(https://kamatama41.hatenablog.com/entry/2019/04/27/100151)- èªè¨¼
- ãã¤ãã¼ãã®æå·å
- ãªã©
使ãæ¹
2019/04/06æç¹ã®ææ°ã¯ 0.2.1
ã§ã
Embulkãµã¼ããèµ·åãã
åºæ¬çã«ã¯Dockerã³ã³ããä¸ã§åãããã¨ãæ³å®ãã¦ãã¦ãDockerHubã«ã¤ã¡ã¼ã¸ããã¹ããã¦ããã®ã§ããããrunããã°èµ·åã§ãã¾ããã¯ã©ã¤ã¢ã³ã(plugin)ã¨åããã¼ã¸ã§ã³ã®ã¤ã¡ã¼ã¸ã使ããã¨ããããããã¾ãããå¤å°éã£ã¦ããã¶ãåãã¾ããã³ã³ããå´ã¯ 30001
çªã®ãã¼ããéãã®ã§*2ãããå
¬éãã¾ãã
$ docker run -p 30001:30001 -it --rm kamatama41/embulk-executor-remoteserver 14:55:48.805 [main] INFO c.g.kamatama41.nsocket.SocketServer - Starting server..
Embulkãèµ·åãã
exec
ã« type: remoteserver
ãæå®ã㦠hosts
ã«èµ·åä¸ã®Embulkãµã¼ãã®ãã¹ããç»é²ãã¾ãã
exec: type: remoteserver hosts: - localhost:30001
ãã®ç¶æ ã§Embulk runãããã¨ããµã¼ãã«æ¥ç¶ã«è¡ããã¿ã¹ã¯ã®å®è¡ãä¾é ¼ãã¾ãã ãã£ã¨è©³ãããã¥ã¼ããªã¢ã«ã¯ããã¡ãã®example ãåç §ãã¦ãã ããã
ä¸èº«ã®è©±
ãã®ãã©ã°ã¤ã³ã¯ãæå®ãããEmbulkãµã¼ãã¨TCPã³ãã¯ã·ã§ã³ãå¼µãããã®ã³ãã¯ã·ã§ã³ãéãã¦ã¯ã©ã¤ã¢ã³ãã¨ãµã¼ããç¸äºã«ãã¼ã¿ã®ããåããè¡ãã¾ããä¾ãã°ã¯ã©ã¤ã¢ã³ãããã¯EmbulkEmbedãæ§ç¯ããã®ã«å¿ è¦ãªã¿ã¹ã¯ã®æ å ±ãã·ã¹ãã ã³ã³ãã£ã°ãOSSã®ãã©ã°ã¤ã³ãå®è¡ã«å¿ è¦ãªgemãZIPãã¡ã¤ã«ã«ã¾ã¨ãã¦éã£ãããã¦ãã¾ããéã«ãµã¼ãããã¯ã¯ã©ã¤ã¢ã³ãã«åã¿ã¹ã¯ã®é²æç¶æ³ãéã£ã¦ãããã¯ã©ã¤ã¢ã³ãå´ã¯çµäºã®éç¥ãæ¥ãã¾ã§å¾ åããã¾ãã
ããããWebSocketçãªåæ¹åéä¿¡ããã¦ããã®ã§ããããã®ä»çµã¿ãèªä½ãã¾ããã
ã¾ãnettyã¨ã使ã£ã¦WebSocketã«ãã¦ãè¯ãã£ãã®ã§ãããããã¾ãä¾åã©ã¤ãã©ãªãå¢ãããããªãã£ãã®ã¨ãããã¯ã¼ã¯ããã°ã©ãã³ã°ã®åå¼·ãå
¼ãã¦ã¹ã¯ã©ããã§ä½ã£ã¦ã¿ããã£ãã¨ãã次第ã§ããnsocket
㯠NIOã§ä½ã£ããã³ããããã³ã°socketãµã¼ãã¨ã¯ã©ã¤ã¢ã³ã
ã®ç¥ã§ãã大å¤ã ã£ããã©çµæ§ããåå¼·ã«ãªãã¾ããã
å®ç¨æ§ããããã¯å¾®å¦ãªã¨ããã§ãããããã£ãã使ã£ã¦ã¿ã¦ææ³ãããã ããã¨åã³ã¾ãã