Skip to content

Commit

Permalink
Alert for port conflicts (#218)
Browse files Browse the repository at this point in the history
Signed-off-by: wayblink <anyang.wang@zilliz.com>
  • Loading branch information
wayblink authored Oct 9, 2023
1 parent 60bfe7c commit 37fee07
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion core/backup_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"github.com/zilliztech/milvus-backup/core/paramtable"
"github.com/zilliztech/milvus-backup/core/proto/backuppb"
"github.com/zilliztech/milvus-backup/internal/log"
"go.uber.org/zap"
"net/http"
"net/http/pprof"
)
Expand Down Expand Up @@ -57,7 +58,11 @@ func (s *Server) Init() {

func (s *Server) Start() {
s.registerProfilePort()
s.engine.Run(s.config.port)
err := s.engine.Run(s.config.port)
if err != nil {
log.Error("Failed to start server", zap.Error(err))
panic(err)
}
log.Info("Start backup server backend")
}

Expand Down

0 comments on commit 37fee07

Please sign in to comment.