|
@@ -43,12 +43,12 @@ func init() {
|
|
|
data_db, _ := orm.GetDB("data")
|
|
|
data_db.SetConnMaxLifetime(10 * time.Minute)
|
|
|
|
|
|
- //_ = orm.RegisterDataBase("eta", "mysql", utils.MYSQL_URL_ETA)
|
|
|
- //orm.SetMaxIdleConns("eta", 50)
|
|
|
- //orm.SetMaxOpenConns("eta", 100)
|
|
|
+ _ = orm.RegisterDataBase("eta", "mysql", utils.MYSQL_URL_ETA)
|
|
|
+ orm.SetMaxIdleConns("eta", 50)
|
|
|
+ orm.SetMaxOpenConns("eta", 100)
|
|
|
|
|
|
- //etaDb, _ := orm.GetDB("eta")
|
|
|
- //etaDb.SetConnMaxLifetime(10 * time.Minute)
|
|
|
+ etaDb, _ := orm.GetDB("eta")
|
|
|
+ etaDb.SetConnMaxLifetime(10 * time.Minute)
|
|
|
|
|
|
orm.Debug = true
|
|
|
orm.DebugLog = orm.NewLog(utils.Binlog)
|