codingapi / codingapi/tx-lcn

当TX-LCN开启了日志配置之后, 数据库连接角色没有创建表权限, 启动报错

Aperta
#477 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Java
Stelle
4.2k
Fork
1.4k
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

## Why you need it?
Is your feature request related to a problem? Please describe in details
希望在LogDbProperties 在这个类中添加一个checkout属性, 并且在MysqlLoggerHelper类中init()方法改变判断条件, 由我们自己决定是否开启创建表语句

## How it could be?
A clear and concise description of what you want to happen. You can explain more about input of the feature, and output of it.

## Other related information
Add any other context or screenshots about the feature request here.
@Override
public void init() {
if (logDbProperties.isCheckOut()) {
String sql = "CREATE TABLE IF NOT EXISTS `t_logger` (\n" +
" `id` bigint(20) NOT NULL AUTO_INCREMENT,\n" +
" `group_id` varchar(64) NOT NULL ,\n" +
" `unit_id` varchar(32) NOT NULL ,\n" +
" `tag` varchar(50) NOT NULL ,\n" +
" `content` varchar(1024) NOT NULL ,\n" +
" `create_time` varchar(30) NOT NULL,\n" +
" `app_name` varchar(128) NOT NULL,\n" +
" PRIMARY KEY (`id`) USING BTREE\n" +
") ";
dbHelper.update(sql);
}

}

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.