|
|
@ -4,6 +4,7 @@ import (
|
|
|
|
"fmt"
|
|
|
|
"fmt"
|
|
|
|
"github.com/jinzhu/gorm"
|
|
|
|
"github.com/jinzhu/gorm"
|
|
|
|
"github.com/taoshihan1991/imaptool/config"
|
|
|
|
"github.com/taoshihan1991/imaptool/config"
|
|
|
|
|
|
|
|
"github.com/taoshihan1991/imaptool/tools"
|
|
|
|
"time"
|
|
|
|
"time"
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
@ -26,7 +27,7 @@ func init() {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
DB.SingularTable(true)
|
|
|
|
DB.SingularTable(true)
|
|
|
|
DB.LogMode(true)
|
|
|
|
DB.LogMode(true)
|
|
|
|
//DB.SetLogger(tools.Logger())
|
|
|
|
DB.SetLogger(tools.Logger())
|
|
|
|
DB.DB().SetMaxIdleConns(10)
|
|
|
|
DB.DB().SetMaxIdleConns(10)
|
|
|
|
DB.DB().SetMaxOpenConns(100)
|
|
|
|
DB.DB().SetMaxOpenConns(100)
|
|
|
|
|
|
|
|
|
|
|
|