当前位置:网站首页>Flink reads MySQL and PgSQL at the same time, and the program will get stuck without logs
Flink reads MySQL and PgSQL at the same time, and the program will get stuck without logs
2022-04-23 08:48:00 【zs_ bigdata】
One . problem
As the title ,flink The program will always get stuck initialize Stage , And there will be no logs
Two . solve
Read from the program mysql And pgsql The way to use is :
DriverManager.getConnection(URL, USERNAME, PASSWORD);
test , If only mysql, Or just ask pgsql There are normal data , At this point I wonder if there is a problem with this method
hold mysql Request to use the druid to get the connection instead
dataSource = new DruidDataSource();
dataSource.setDriverClassName(MysqlConfig.DriverName);
dataSource.setUrl(MysqlConfig.MYSQL_URL);
dataSource.setUsername(MysqlConfig.USERNAME);
dataSource.setPassword(MysqlConfig.PASSWORD);
dataSource.getConnection();
Restart the program , After discovery, you can request two databases at the same time
3、 ... and . doubt
I don't know whether this method has this limitation or flink Internally caused , I hope you can give me some advice
DriverManager.getConnection(URL, USERNAME, PASSWORD);
版权声明
本文为[zs_ bigdata]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230847378438.html
边栏推荐
- 2021 Li Hongyi's adaptive learning rate of machine learning
- Flash project cross domain interception and DBM database learning [Baotou cultural and creative website development]
- Play with binary tree (25 points)
- Virtual online exhibition - Online VR exhibition hall realizes 24h immersive exhibition viewing
- flask项目跨域拦截处理以及dbm数据库学习【包头文创网站开发】
- Go语言自学系列 | golang方法
- PDF with watermark
- 是否同一棵二叉搜索树 (25 分)
- L2-3 浪漫侧影 (25 分)
- Use include in databinding
猜你喜欢
Notes on 30 steps of introduction to the Internet of things of yangtao electronics STM32 III. cubemx graphical programming and setting the IO port on the development board
Solidity 问题汇总
OneFlow学习笔记:从Functor到OpExprInterpreter
L2-024 部落 (25 分)(并查集)
cadence的工艺角仿真、蒙特卡洛仿真、PSRR
MySQL查询两张表属性值非重复的数据
After a circle, I sorted out this set of interview questions..
Correct method of calculating inference time of neural network
PCTP考试经验分享
请提前布局 Star Trek突破链游全新玩法,市场热度持续高涨
随机推荐
L2-024 部落 (25 分)(并查集)
PgSQL wants to implement all kinds of column sub query operations of MySQL
洋桃电子STM32物联网入门30步笔记三、新建CubeIDE工程和设置讲解
请问中衍期货安全靠谱吗?
LaTeX论文排版操作
Use include in databinding
PDF with watermark
错误: 找不到或无法加载主类
面了一圈,整理了这套面试题。。
Add random attributes to the Li class array objects and sort them
关于cin,scanf和getline,getchar,cin.getline的混合使用
L2-022 rearrange linked list (25 points) (map + structure simulation)
PCTP考试经验分享
uni-app和微信小程序中的getCurrentPages()
扣缴义务人
Redis Desktop Manager for Mac(Redis可视化工具)
L2-3 浪漫侧影 (25 分)
共享办公室,提升入驻体验
idea打包 jar文件
应纳税所得额