You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
733 B
26 lines
733 B
package com.fr.plugin.migration.pgsql; |
|
|
|
import com.fanruan.api.log.LogKit; |
|
import com.fr.stable.fun.impl.AbstractDataSourceDriverLoader; |
|
|
|
/** |
|
* 迁移前,数据库测试连接处的过滤 |
|
* |
|
* @author lidongy |
|
* @version 10.0 |
|
* Created by lidongy on 2020/11/18 |
|
*/ |
|
public class PGSQLClassLoaderHandler extends AbstractDataSourceDriverLoader { |
|
public boolean isInterceptAllowed(String databaseType, String url) { |
|
if (url.startsWith("jdbc:postgresql")) { |
|
LogKit.info("[com.fr.plugin.connection.mysql8] The connection has been intercepted."); |
|
return true; |
|
} |
|
return false; |
|
} |
|
|
|
public ClassLoader getClassLoader() { |
|
return this.getClass().getClassLoader(); |
|
} |
|
|
|
}
|
|
|