mirror of
https://github.com/yanislav-igonin/micrach
synced 2024-12-22 14:22:33 +03:00
feat: disable gin logs
This commit is contained in:
parent
35131c4ff8
commit
6ef39c6726
1
db/db.go
1
db/db.go
@ -19,6 +19,7 @@ func Init() {
|
|||||||
log.Panicln(err)
|
log.Panicln(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: take from config from env var
|
||||||
Pool.Config().MaxConns = 5
|
Pool.Config().MaxConns = 5
|
||||||
|
|
||||||
log.Println("database - online")
|
log.Println("database - online")
|
||||||
|
3
main.go
3
main.go
@ -41,7 +41,8 @@ func main() {
|
|||||||
instance := limiter.New(store, rate)
|
instance := limiter.New(store, rate)
|
||||||
middleware := mgin.NewMiddleware(instance)
|
middleware := mgin.NewMiddleware(instance)
|
||||||
|
|
||||||
router := gin.Default()
|
router := gin.New()
|
||||||
|
router.Use(gin.Recovery())
|
||||||
router.SetFuncMap(template.FuncMap{
|
router.SetFuncMap(template.FuncMap{
|
||||||
"Iterate": func(count int) []int {
|
"Iterate": func(count int) []int {
|
||||||
var i int
|
var i int
|
||||||
|
Loading…
Reference in New Issue
Block a user