抽离 logger

This commit is contained in:
Shikong 2023-03-24 11:46:51 +08:00
parent 1037ae3923
commit 0e3f8380f0
10 changed files with 9 additions and 9 deletions

View File

@ -4,10 +4,10 @@ import (
"github.com/fsnotify/fsnotify"
"github.com/spf13/viper"
"matrix-common/constants"
"matrix-common/pkg/logger"
_ "matrix-middle-service/docs"
"matrix-middle-service/internel/app"
"matrix-middle-service/pkg/config/toml"
"matrix-middle-service/pkg/logger"
)
func Main() {

View File

@ -4,11 +4,11 @@ import (
"encoding/json"
"github.com/gofiber/fiber/v2"
"github.com/spf13/viper"
"matrix-common/pkg/logger"
"matrix-middle-service/internel/middleware"
"matrix-middle-service/internel/route"
"matrix-middle-service/pkg/config"
"matrix-middle-service/pkg/database"
"matrix-middle-service/pkg/logger"
fib "matrix-middle-service/pkg/utils/fiber"
"matrix-middle-service/pkg/utils/nanoid"
"matrix-middle-service/pkg/utils/sonyflake"

View File

@ -2,10 +2,10 @@ package location
import (
"github.com/gofiber/fiber/v2"
"matrix-common/pkg/logger"
"matrix-middle-service/internel/controller/record/location/dto"
"matrix-middle-service/pkg/database"
"matrix-middle-service/pkg/database/model"
"matrix-middle-service/pkg/logger"
response "matrix-middle-service/pkg/resp"
"matrix-middle-service/pkg/resp/errorx"
utils "matrix-middle-service/pkg/utils/json"

View File

@ -2,7 +2,7 @@ package route
import (
"github.com/gofiber/fiber/v2"
"matrix-middle-service/pkg/logger"
"matrix-common/pkg/logger"
"matrix-middle-service/pkg/resp/errorx"
)

View File

@ -1,9 +1,9 @@
package main
import (
_ "matrix-common/pkg/logger"
"matrix-middle-service/cmd/service"
_ "matrix-middle-service/pkg/database/driver/mysql"
_ "matrix-middle-service/pkg/logger"
"time"
)

View File

@ -2,10 +2,10 @@ package database
import (
"github.com/mitchellh/mapstructure"
"matrix-common/pkg/logger"
"matrix-middle-service/internel/controller/record/location/dto"
"matrix-middle-service/pkg/config/database"
"matrix-middle-service/pkg/database/model"
"matrix-middle-service/pkg/logger"
)
var SupportDataSources = make(map[string]InitDSFn)

View File

@ -7,12 +7,12 @@ import (
_ "github.com/go-sql-driver/mysql"
"github.com/gookit/goutil/strutil"
"github.com/mitchellh/mapstructure"
"matrix-common/pkg/logger"
"matrix-middle-service/internel/controller/record/location/dto"
database2 "matrix-middle-service/pkg/config/database"
"matrix-middle-service/pkg/database"
"matrix-middle-service/pkg/database/driver/mysql/conf"
"matrix-middle-service/pkg/database/model"
"matrix-middle-service/pkg/logger"
fib "matrix-middle-service/pkg/utils/fiber"
"strings"
"time"

View File

@ -2,8 +2,8 @@ package nanoid
import (
gonanoid "github.com/matoous/go-nanoid"
"matrix-common/pkg/logger"
"matrix-middle-service/pkg/config/nanoid"
"matrix-middle-service/pkg/logger"
)
var config *nanoid.Config

View File

@ -3,8 +3,8 @@ package sonyflake
import (
"fmt"
"github.com/sony/sonyflake"
"matrix-common/pkg/logger"
sf "matrix-middle-service/pkg/config/sonyflake"
"matrix-middle-service/pkg/logger"
"time"
)