kettle执行job过程中会与repository连接断开
问题:
An error occured loading the directory tree from the repository ERROR executing query
The last packet successfully received from the server was 3,645,796 milliseconds ago.
The last packet sent successfully to the server was 801,805 milliseconds ago.
is longer than the server configured value of 'wait_timeout'. You should consider
either expiring and/or testing connection validity before use in your application,
increasing the server configured values for client timeouts, or using the
Connector/J connection property 'autoReconnect=true' to avoid this problem
看问题可以发现是连接超时的问题,但并不知道在何处配置参数可以修改这个问题。
网上查看中文资料并没有相关解决方案,最后在官网的文档上找到解决办法。
MySQL Another issue you may encounter is that the default timeout in the MySQL
JDBC driver is set to 0 (no timeout). In certain instances, this may not
allow Kettle to detect a server crash or sudden network failure if it
occurs in the middle of a query or open database connection. This in turn
leads to the infinite stalling of a transformation or job. To solve problem,
set the "connectTimeout" and "socketTimeout" parameters for MySQL in the
Options tab. The value to be specified is in milliseconds: for a 2 minute
timeout you would specify value 120000 ( 2 x 60 x 1000 ). You can also
review other options on the linked MySQL help page by clicking on the 'Show
help text on option usage' button found on the Options tab.
然后修改
autoReconnect=true
connectTimeout=120000
socketTimeout=120000