Update TSDBDriver.java
多数据源下,driver驱动根据acceptsURL判断url使用合适的驱动,增加判断TAOS驱动
This commit is contained in:
parent
dfbe9ace8a
commit
d3aaceedb5
|
@ -188,7 +188,7 @@ public class TSDBDriver implements java.sql.Driver {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean acceptsURL(String url) throws SQLException {
|
public boolean acceptsURL(String url) throws SQLException {
|
||||||
return true;
|
return StringUtils.isNotBlank(url) && url.startsWith(URL_PREFIX);
|
||||||
}
|
}
|
||||||
|
|
||||||
public DriverPropertyInfo[] getPropertyInfo(String url, Properties info) throws SQLException {
|
public DriverPropertyInfo[] getPropertyInfo(String url, Properties info) throws SQLException {
|
||||||
|
@ -355,4 +355,4 @@ public class TSDBDriver implements java.sql.Driver {
|
||||||
public String database(Properties props) {
|
public String database(Properties props) {
|
||||||
return props.getProperty(PROPERTY_KEY_DBNAME);
|
return props.getProperty(PROPERTY_KEY_DBNAME);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue