@@ -164,9 +164,9 @@ public String getDBVersion() {
164
164
if (isDb2 ()) {
165
165
return "11.5" ; //TODO 改成你自己的
166
166
}
167
- // if (isSQLite()) {
168
- // return "3.39.3"; //TODO 改成你自己的
169
- // }
167
+ // if (isSQLite()) {
168
+ // return "3.39.3"; //TODO 改成你自己的
169
+ // }
170
170
if (isDameng ()) {
171
171
return "8.1.2.141" ; //TODO 改成你自己的
172
172
}
@@ -212,17 +212,17 @@ public String getDBUri() {
212
212
213
213
if (isMySQL ()) {
214
214
// 这个是 MySQL 8.0 及以上,要加 userSSL=false
215
- // return "jdbc:mysql://47.122.25.116:3306?userSSL=false&serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=UTF-8";
215
+ // return "jdbc:mysql://47.122.25.116:3306?userSSL=false&serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=UTF-8";
216
216
// 以下是 MySQL 5.7 及以下
217
217
return "jdbc:mysql://localhost:3306?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=UTF-8" ; //TODO 改成你自己的,TiDB 可以当成 MySQL 使用,默认端口为 4000
218
218
}
219
219
if (isPostgreSQL ()) { // PG JDBC 必须在 URI 传 catalog
220
220
return "jdbc:postgresql://localhost:5432/postgres?stringtype=unspecified" ; //TODO 改成你自己的
221
221
}
222
- //if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
223
- // return "jdbc:postgresql://localhost:26257/movr?sslmode=require"; //TODO 改成你自己的 brew install cockroachdb/tap/cockroach && cockroach demo
224
- // // return "jdbc:postgresql://localhost:26258/postgres?sslmode=disable"; //TODO 改成你自己的 brew install cockroachdb/tap/cockroach # && start 3 nodes and init cluster
225
- //}
222
+ // if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
223
+ // return "jdbc:postgresql://localhost:26257/movr?sslmode=require"; //TODO 改成你自己的 brew install cockroachdb/tap/cockroach && cockroach demo
224
+ // // return "jdbc:postgresql://localhost:26258/postgres?sslmode=disable"; //TODO 改成你自己的 brew install cockroachdb/tap/cockroach # && start 3 nodes and init cluster
225
+ // }
226
226
if (isSQLServer ()) {
227
227
return "jdbc:jtds:sqlserver://localhost:1433/pubs;instance=SQLEXPRESS" ; //TODO 改成你自己的
228
228
}
@@ -232,25 +232,28 @@ public String getDBUri() {
232
232
if (isDb2 ()) {
233
233
return "jdbc:db2://localhost:50000/BLUDB" ; //TODO 改成你自己的
234
234
}
235
- // if (isSQLite()) {
236
- // return "jdbc:sqlite:sample.db"; //TODO 改成你自己的
237
- // }
235
+ // if (isSQLite()) {
236
+ // return "jdbc:sqlite:sample.db"; //TODO 改成你自己的
237
+ // }
238
238
if (isDameng ()) {
239
239
return "jdbc:dm://localhost:5236" ; //TODO 改成你自己的
240
240
}
241
241
if (isTDengine ()) {
242
242
// return "jdbc:TAOS://localhost:6030"; //TODO 改成你自己的
243
243
return "jdbc:TAOS-RS://localhost:6041" ; //TODO 改成你自己的
244
244
}
245
+ // if (isTimescaleDB()) { // PG JDBC 必须在 URI 传 catalog
246
+ // return "jdbc:postgresql://localhost:5432/postgres?stringtype=unspecified"; //TODO 改成你自己的
247
+ // }
245
248
if (isInfluxDB ()) {
246
249
return "http://203.189.6.3:8086" ; //TODO 改成你自己的
247
250
}
248
251
if (isMilvus ()) {
249
252
return "http://localhost:19530" ; //TODO 改成你自己的
250
253
}
251
- //if (isManticore()) {
252
- // return "jdbc:mysql://localhost:9306?characterEncoding=utf8&maxAllowedPacket=512000"; //TODO 改成你自己的
253
- //}
254
+ // if (isManticore()) {
255
+ // return "jdbc:mysql://localhost:9306?characterEncoding=utf8&maxAllowedPacket=512000"; //TODO 改成你自己的
256
+ // }
254
257
// if (isIoTDB()) {
255
258
// return "jdbc:iotdb://localhost:6667"; // ?charset=GB18030 加参数会报错 URI 格式错误 //TODO 改成你自己的
256
259
// }
@@ -293,10 +296,10 @@ public String getDBAccount() {
293
296
if (isPostgreSQL ()) {
294
297
return "postgres" ; //TODO 改成你自己的
295
298
}
296
- //if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
297
- // return "demo"; //TODO 改成你自己的
298
- // //return "postgres"; //TODO 改成你自己的
299
- //}
299
+ // if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
300
+ // return "demo"; //TODO 改成你自己的
301
+ // //return "postgres"; //TODO 改成你自己的
302
+ // }
300
303
if (isSQLServer ()) {
301
304
return "sa" ; //TODO 改成你自己的
302
305
}
@@ -306,24 +309,27 @@ public String getDBAccount() {
306
309
if (isDb2 ()) {
307
310
return "db2admin" ; //TODO 改成你自己的
308
311
}
309
- // if (isSQLite()) {
310
- // return "root"; //TODO 改成你自己的
311
- // }
312
+ // if (isSQLite()) {
313
+ // return "root"; //TODO 改成你自己的
314
+ // }
312
315
if (isDameng ()) {
313
316
return "SYSDBA" ;
314
317
}
315
318
if (isTDengine ()) {
316
319
return "root" ; //TODO 改成你自己的
317
320
}
321
+ // if (isTimescaleDB()) {
322
+ // return "postgres"; //TODO 改成你自己的
323
+ // }
318
324
if (isInfluxDB ()) {
319
325
return "iotos" ;
320
326
}
321
327
if (isMilvus ()) {
322
328
return "root" ;
323
329
}
324
- //if (isManticore()) {
325
- // return null; // "root";
326
- //}
330
+ // if (isManticore()) {
331
+ // return null; // "root";
332
+ // }
327
333
// if (isIoTDB()) {
328
334
// return "root";
329
335
// }
@@ -365,10 +371,10 @@ public String getDBPassword() {
365
371
if (isPostgreSQL ()) {
366
372
return null ; //TODO 改成你自己的
367
373
}
368
- //if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
369
- // return "demo39865"; //TODO 改成你自己的
370
- // // return null; //TODO 改成你自己的
371
- //}
374
+ // if (isCockroachDB()) { // PG JDBC 必须在 URI 传 catalog
375
+ // return "demo39865"; //TODO 改成你自己的
376
+ // // return null; //TODO 改成你自己的
377
+ // }
372
378
if (isSQLServer ()) {
373
379
return "apijson@123" ; //TODO 改成你自己的
374
380
}
@@ -378,24 +384,27 @@ public String getDBPassword() {
378
384
if (isDb2 ()) {
379
385
return "123" ; //TODO 改成你自己的
380
386
}
381
- // if (isSQLite()) {
382
- // return "apijson"; //TODO 改成你自己的
383
- // }
387
+ // if (isSQLite()) {
388
+ // return "apijson"; //TODO 改成你自己的
389
+ // }
384
390
if (isDameng ()) {
385
391
return "SYSDBA" ;
386
392
}
387
393
if (isTDengine ()) {
388
394
return "taosdata" ; //TODO 改成你自己的
389
395
}
396
+ // if (isTimescaleDB()) {
397
+ // return "password"; //TODO 改成你自己的
398
+ // }
390
399
if (isInfluxDB ()) {
391
400
return "apijson@123" ; //TODO 改成你自己的
392
401
}
393
402
if (isMilvus ()) {
394
403
return "apijson" ; //TODO 改成你自己的
395
404
}
396
- //if (isManticore()) {
397
- // return null;
398
- //}
405
+ // if (isManticore()) {
406
+ // return null;
407
+ // }
399
408
// if (isIoTDB()) {
400
409
// return "root";
401
410
// }
0 commit comments