Skip to content

Commit 610960c

Browse files
committed
update: 优化默认参数设置,默认显示gtid和时间
1 parent 5167f31 commit 610960c

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

cmd/bingo2sql.go

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,8 @@ var (
7777

7878
showGTID = flagBoolean("show-gtid", "", true, "显示gtid")
7979
showTime = flagBoolean("show-time", "", true, "显示执行时间,同一时间仅显示首次")
80-
showAllTime = flagBoolean("show-all-time", "", true, "显示每条SQL的执行时间")
81-
showThread = flagBoolean("show-thread", "", true, "显示线程号,便于区别同一进程操作")
80+
showAllTime = flagBoolean("show-all-time", "", false, "显示每条SQL的执行时间")
81+
showThread = flagBoolean("show-thread", "", false, "显示线程号,便于区别同一进程操作")
8282

8383
debug = flagBoolean("debug", "", false, "调试模式,输出详细日志")
8484
)
@@ -350,7 +350,11 @@ func getAllParse(c echo.Context) error {
350350
}
351351

352352
func parseBinlog(c echo.Context) error {
353-
cfg := new(parser.BinlogParserConfig)
353+
354+
cfg := &parser.BinlogParserConfig{
355+
ShowGTID: true,
356+
ShowTime: true,
357+
}
354358

355359
if err := c.Bind(cfg); err != nil {
356360
return err

0 commit comments

Comments
 (0)