mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
fix url prefix jdbc:oceanbase:oracle recognize error
Signed-off-by: hongwei yi hongweiyi@hotmail.com workaround: if you need use oceanbase oracle type in Druid previous version, please use DruidDataSource.setDbType("oceanbase_oracle") instead
This commit is contained in:
@@ -30,6 +30,11 @@ public class JdbcUtils_driver extends TestCase {
|
||||
Assert.assertEquals(JdbcConstants.ODPS, JdbcUtils.getDbTypeRaw(url, className));
|
||||
}
|
||||
|
||||
public void test_oceanbase() {
|
||||
assertEquals(JdbcConstants.OCEANBASE, DbType.of(JdbcUtils.getDbType("jdbc:oceanbase://127.1:3306/test?a=b", null)));
|
||||
assertEquals(JdbcConstants.OCEANBASE_ORACLE, DbType.of(JdbcUtils.getDbType("jdbc:oceanbase:oracle://127.1:3306/test?a=b", null)));
|
||||
}
|
||||
|
||||
public void test_log4jdbc_mysql() {
|
||||
String jdbcUrl = "jdbc:log4jdbc:mysql://localhost:8066/test";
|
||||
DbType dbType = JdbcUtils.getDbTypeRaw(jdbcUrl, null);
|
||||
|
||||
Reference in New Issue
Block a user