fix create errors and log
This commit is contained in:
1 parent
c46003d882
commit
fcc57459ef
2 files changed
+4
-3
No files matched your search
@@ -2,7 +2,6 @@ package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"log"
|
||||
"os"
|
||||
|
||||
"github.com/integration-system/isp-lib/v2/bootstrap"
|
||||
@@ -10,6 +9,7 @@ import (
|
||||
"github.com/integration-system/isp-lib/v2/config/schema"
|
||||
"github.com/integration-system/isp-lib/v2/metric"
|
||||
"github.com/integration-system/isp-lib/v2/structure"
|
||||
log "github.com/integration-system/isp-log"
|
||||
"github.com/integration-system/isp-log/stdcodes"
|
||||
"isp-gate-service/accounting"
|
||||
"isp-gate-service/authenticate"
|
||||
@@ -101,7 +101,7 @@ func handleRouteUpdate(configs structure.RoutingConfig) bool {
|
||||
routing.InitRoutes(configs)
|
||||
err := proxy.InitProxiesFromConfigs(configs)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
log.Error(400, err)
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
+2
-1
@@ -79,7 +79,8 @@ func InitProxiesFromConfigs(configs structure.RoutingConfig) error {
|
||||
for protocol, info := range config.HandlersInfo {
|
||||
p, err := makeProxy(protocol, info.SkipAuth, info.SkipExistCheck)
|
||||
if err != nil {
|
||||
return fmt.Errorf("%v bad dynamic config in service %s with protocol %s", err, config.ModuleName, protocol)
|
||||
errMsg := fmt.Sprintf("%v bad dynamic config in service %s with protocol %s", err, config.ModuleName, protocol)
|
||||
return errors.New(errMsg)
|
||||
}
|
||||
addressConfig := []structure.AddressConfiguration{{
|
||||
Port: info.Port,
|
||||
|
||||
Reference in new issue
Block a user