mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-02-24 22:49:06 -06:00
dead code
This commit is contained in:
@@ -1,13 +1,8 @@
|
||||
package runtime
|
||||
|
||||
import (
|
||||
"os"
|
||||
|
||||
mzlog "github.com/asim/go-micro/plugins/logger/zerolog/v3"
|
||||
"github.com/asim/go-micro/v3/logger"
|
||||
"github.com/owncloud/ocis/ocis-pkg/config"
|
||||
"github.com/owncloud/ocis/ocis/pkg/runtime/service"
|
||||
"github.com/rs/zerolog"
|
||||
)
|
||||
|
||||
// Runtime represents an oCIS runtime environment.
|
||||
@@ -26,17 +21,3 @@ func New(cfg *config.Config) Runtime {
|
||||
func (r *Runtime) Start() error {
|
||||
return service.Start(service.WithConfig(r.c))
|
||||
}
|
||||
|
||||
// for logging reasons we don't want the same logging level on both oCIS and micro. As a framework builder we do not
|
||||
// want to expose to the end user the internal framework logs unless explicitly specified.
|
||||
func setMicroLogger(log config.Log) {
|
||||
if os.Getenv("MICRO_LOG_LEVEL") == "" {
|
||||
os.Setenv("MICRO_LOG_LEVEL", "error")
|
||||
}
|
||||
|
||||
lev, err := zerolog.ParseLevel(os.Getenv("MICRO_LOG_LEVEL"))
|
||||
if err != nil {
|
||||
lev = zerolog.ErrorLevel
|
||||
}
|
||||
logger.DefaultLogger = mzlog.NewLogger(logger.WithLevel(logger.Level(lev)))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user