mysql 8使用美团的Leaf算法(segment)需要修改的地方
直通车:https://github.com/Meituan-Dianping/Leaf

1、leaf.properties修改以下地方 记得加 SERVERTIMEZONE

leaf.name=com.sankuai.leaf.opensource.test leaf.segment.enable=true leaf.jdbc.url=jdbc:mysql://localhost:3306/leaf?autoReconnect=true&useSSL=false&serverTimezone=Hongkong leaf.jdbc.driver-class-name=com.mysql.cj.jdbc.Driver leaf.jdbc.username=root leaf.jdbc.password=rootleaf.snowflake.enable=false #leaf.snowflake.zk.address= #leaf.snowflake.port=
2、父工程中的poem文件中修改下连接的版本
8.0.14
3、 com.sankuai.inf.leaf.server.Constants 加一个字段
public static final String driver = "leaf.jdbc.driver-class-name";
4、com.sankuai.inf.leaf.server.service.SegmentService 读取该属性
dataSource.setDriverClassName(properties.getProperty(Constants.driver));
本文来自互联网用户投稿,文章观点仅代表作者本人,不代表本站立场,不承担相关法律责任。如若转载,请注明出处。 如若内容造成侵权/违法违规/事实不符,请点击【内容举报】进行投诉反馈!
