keon94 commented on code in PR #2656:
URL: https://github.com/apache/incubator-devlake/pull/2656#discussion_r945019713


##########
logger/logger.go:
##########
@@ -23,19 +23,39 @@ import (
        "github.com/sirupsen/logrus"
        "io"
        "os"
-       "regexp"
+       "path/filepath"
 )
 
+const defaultLogFilename = "devlake"
+const defaultBasePath = "./logs"
+
 type DefaultLogger struct {
-       prefix     string
-       log        *logrus.Logger
-       loggerPool map[string]*logrus.Logger
+       prefix    string
+       log       *logrus.Logger
+       pool      map[string]core.Logger
+       basePath  string
+       directory string
+       filename  string
 }
 
-func NewDefaultLogger(log *logrus.Logger, prefix string, loggerPool 
map[string]*logrus.Logger) *DefaultLogger {
-       newDefaultLogger := &DefaultLogger{prefix: prefix, log: log}
-       newDefaultLogger.loggerPool = loggerPool
-       return newDefaultLogger
+func NewDefaultLogger(log *logrus.Logger, rootLogDir string) (core.Logger, 
error) {
+       if rootLogDir == "" {
+               rootLogDir = defaultBasePath

Review Comment:
   issue #2742 created



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to