惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

The GitHub Blog
The GitHub Blog
雷峰网
雷峰网
小众软件
小众软件
博客园 - 【当耐特】
J
Java Code Geeks
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
Hugging Face - Blog
Hugging Face - Blog
腾讯CDC
Engineering at Meta
Engineering at Meta
aimingoo的专栏
aimingoo的专栏
A
About on SuperTechFans
H
Help Net Security
博客园_首页
P
Proofpoint News Feed
GbyAI
GbyAI
大猫的无限游戏
大猫的无限游戏
N
Netflix TechBlog - Medium
爱范儿
爱范儿
MyScale Blog
MyScale Blog
Blog — PlanetScale
Blog — PlanetScale
The Cloudflare Blog
MongoDB | Blog
MongoDB | Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
Google DeepMind News
Google DeepMind News

博客园 - 阳光沙滩海岸线

一次曲折的单点集成之旅 一次IIS问题排查 Awesome .NET - 阳光沙滩海岸线 - 博客园 注意IE的Cookie个数限制问题 - 阳光沙滩海岸线 - 博客园 关于SQL数据库强制还原 Excel求和 检索 COM 类工厂中的组件时失败,原因是出现以下错误: 8007007e Prototype的验证框架 主域名与子目录访问的问题 - 阳光沙滩海岸线 - 博客园 一个比较好用的DBHelper 关于IIS7下打开ASP错误的方法总结 - 阳光沙滩海岸线 - 博客园 靠死腾讯,QQ2009不能安装也不能删…… 关于GridView中绑定TemplateField值丢失的问题 今天买了个黑莓7290 MSN 2009在2008下面的问题 SSIS包能不能在其它环境独立执行? PJBlog的文章转换成BlogEngine的xml格式文章 VS2008出现问题,package load failure 测试Writer
发布支持mysql8.0的writer和reader
阳光沙滩海岸线 · 2020-08-02 · via 博客园 - 阳光沙滩海岸线

默认从官网下载的datax,是不支持mysql8.0的。直接调用会报错。
Description:[连接数据库失败. 请检查您的 账号、密码、数据库名称、IP、Port或者向 DBA 寻求帮助(注意网络环境).]. - 具体错误信息为:com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Could not create connection to database server.

要修正问题很简单,将pom.xml的库更新为8.0,再重新编译就可以了。
为了避免麻烦,我已经打包好。需要的人可以直接下载,覆蓋原文件就可以了。

编译参考文章:
https://www.cnblogs.com/zifan/p/12550747.html

mysqlwriter,mysqlreader下载链接
https://wws.lanzous.com/b01hkhkij
密码:37ca

附,我的同步job
{ "job": { "content": [ { "reader": { "name": "mysqlreader", "parameter": { "connection": [ { "jdbcUrl": ["jdbc:mysql://0.0.0.:3306/db?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&useSSL=false"], "querySql":[ "select MonitorPointID, ProjectID, PointName, Mileage, Remark,'JK-ZBTT-DSFJC-Inclinometer' as DataCode, CreateUserId, CreateUserName, CreateDate, ModifyUserId, ModifyUserName, ModifyDate from qc_monitorpoint where CustomMonitorCode='CX' and ProjectID='c23bd52e-50f7-4dda-9c2c-f325dee12b17'" ] } ], "password": "password", "username": "username" } }, "writer": { "name": "mysqlwriter", "parameter": { "column": [ "PointID", "ProjectID", "PointName", "Mileage", "Remark", "DataCode", "CreateUserId", "CreateUserName", "CreateDate", "ModifyUserId", "ModifyUserName", "ModifyDate"], "connection": [ { "jdbcUrl": "jdbc:mysql://localhost:3306/db?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&useSSL=false", "table": ["fp_points"] } ], "password": "password", "preSql": [], "session": [], "username": "username", "writeMode": "update" } } } ], "setting": { "speed": { "channel": "1" } } } }