caoes opened a new issue, #10270: URL: https://github.com/apache/dolphinscheduler/issues/10270
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar issues. ### What happened First, enter the correct data source account password for connection test, wait for the message that the link is successful, save the data source. Then edit the data source, enter the wrong password for editing, editing success. ### What you expected to happen org.apache.dolphinscheduler.plugin.datasource.api.datasourceAbstractDatasourceProcessor##getDatasourceUniqueId method Generate a unique key based only on the type data source user and link information, and skip authentication if the password is incorrect. It is currently found that the mysql data source occasionally requires additional information to connect successfully.{"serverTimezone":"Asia/Shanghai"} Other information must be configured for Hive data type ZK cluster connection mode. If other information is modified, the database cannot be connected .{"serviceDiscoveryMode":"zooKeeper","zooKeeperNamespace":"hiveserver2_zk"} ` public Connection getConnection(DbType dbType, ConnectionParam connectionParam) { BaseConnectionParam baseConnectionParam = (BaseConnectionParam) connectionParam; **_String datasourceUniqueId = DatasourceUtil.getDatasourceUniqueId(baseConnectionParam, dbType);_** logger.info("getConnection datasourceUniqueId {}", datasourceUniqueId); DataSourceClient dataSourceClient = uniqueId2dataSourceClientMap.computeIfAbsent(datasourceUniqueId, $ -> { Map<String, DataSourceChannel> dataSourceChannelMap = dataSourcePluginManager.getDataSourceChannelMap(); DataSourceChannel dataSourceChannel = dataSourceChannelMap.get(dbType.getDescp()); if (null == dataSourceChannel) { throw new RuntimeException(String.format("datasource plugin '%s' is not found", dbType.getDescp())); } return dataSourceChannel.createDataSourceClient(baseConnectionParam, dbType); }); return dataSourceClient.getConnection(); }` `**public String getDatasourceUniqueId(ConnectionParam connectionParam, DbType dbType) { BaseConnectionParam baseConnectionParam = (BaseConnectionParam) connectionParam; return MessageFormat.format("{0}@{1}@{2}@{3}", dbType.getDescp(), baseConnectionParam.getUser(), baseConnectionParam.getPassword(), baseConnectionParam.getJdbcUrl()); }**` ### How to reproduce First, enter the correct data source account password for connection test, wait for the message that the link is successful, save the data source. Then edit the data source, enter the wrong password for editing, editing success. ### Anything else _No response_ ### Version 2.0.5 ### Are you willing to submit PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
