mirror of https://github.com/milvus-io/milvus.git
Unify service name in config file
Signed-off-by: cai.zhang <cai.zhang@zilliz.com>pull/4973/head^2
parent
2302971f77
commit
1d899513dd
|
@ -47,7 +47,6 @@ master:
|
|||
port: 53100
|
||||
|
||||
proxyNode:
|
||||
address: localhost
|
||||
port: 21122
|
||||
|
||||
queryService:
|
||||
|
@ -62,7 +61,7 @@ queryNode:
|
|||
gracefulTime: 5000 #ms
|
||||
port: 21123
|
||||
|
||||
indexServer:
|
||||
indexService:
|
||||
address: localhost
|
||||
port: 31000
|
||||
|
||||
|
@ -74,7 +73,6 @@ dataService:
|
|||
port: 13333
|
||||
|
||||
dataNode:
|
||||
address: localhost
|
||||
port: 21124
|
||||
|
||||
log:
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
package grpcdatanode
|
||||
|
||||
import (
|
||||
"os"
|
||||
"sync"
|
||||
|
||||
"github.com/zilliztech/milvus-distributed/internal/util/funcutil"
|
||||
|
@ -36,10 +35,6 @@ func (pt *ParamTable) LoadFromArgs() {
|
|||
|
||||
func (pt *ParamTable) LoadFromEnv() {
|
||||
Params.IP = funcutil.GetLocalIP()
|
||||
host := os.Getenv("DATA_NODE_HOST")
|
||||
if len(host) > 0 {
|
||||
Params.IP = host
|
||||
}
|
||||
}
|
||||
|
||||
func (pt *ParamTable) initPort() {
|
||||
|
|
|
@ -41,10 +41,6 @@ func (pt *ParamTable) LoadFromEnv() {
|
|||
}
|
||||
|
||||
Params.IP = funcutil.GetLocalIP()
|
||||
host := os.Getenv("INDEX_NODE_HOST")
|
||||
if len(host) > 0 {
|
||||
Params.IP = host
|
||||
}
|
||||
}
|
||||
|
||||
func (pt *ParamTable) initParams() {
|
||||
|
@ -54,7 +50,7 @@ func (pt *ParamTable) initParams() {
|
|||
|
||||
// todo remove and use load from env
|
||||
func (pt *ParamTable) initIndexServerAddress() {
|
||||
addr, err := pt.Load("indexServer.address")
|
||||
addr, err := pt.Load("indexService.address")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
@ -66,7 +62,7 @@ func (pt *ParamTable) initIndexServerAddress() {
|
|||
}
|
||||
}
|
||||
|
||||
port, err := pt.Load("indexServer.port")
|
||||
port, err := pt.Load("indexService.port")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
|
@ -31,11 +31,11 @@ func (pt *ParamTable) initParams() {
|
|||
}
|
||||
|
||||
func (pt *ParamTable) initServicePort() {
|
||||
pt.ServicePort = pt.ParseInt("indexServer.port")
|
||||
pt.ServicePort = pt.ParseInt("indexService.port")
|
||||
}
|
||||
|
||||
func (pt *ParamTable) initServiceAddress() {
|
||||
addr, err := pt.Load("indexServer.address")
|
||||
addr, err := pt.Load("indexService.address")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ func (pt *ParamTable) initServiceAddress() {
|
|||
}
|
||||
}
|
||||
|
||||
port, err := pt.Load("indexServer.port")
|
||||
port, err := pt.Load("indexService.port")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
|
@ -66,7 +66,7 @@ func (s *Server) start() error {
|
|||
if err := s.impl.Start(); err != nil {
|
||||
return err
|
||||
}
|
||||
log.Println("indexServer started")
|
||||
log.Println("indexService started")
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
@ -69,11 +69,6 @@ func (pt *ParamTable) LoadFromEnv() {
|
|||
}
|
||||
|
||||
Params.IP = funcutil.GetLocalIP()
|
||||
host := os.Getenv("PROXY_NODE_HOST")
|
||||
if len(host) > 0 {
|
||||
Params.IP = host
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
func (pt *ParamTable) initParams() {
|
||||
|
@ -116,7 +111,7 @@ func (pt *ParamTable) initProxyServiceAddress() {
|
|||
|
||||
// todo remove and use load from env
|
||||
func (pt *ParamTable) initIndexServerAddress() {
|
||||
addr, err := pt.Load("indexServer.address")
|
||||
addr, err := pt.Load("indexService.address")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
@ -124,11 +119,11 @@ func (pt *ParamTable) initIndexServerAddress() {
|
|||
hostName, _ := net.LookupHost(addr)
|
||||
if len(hostName) <= 0 {
|
||||
if ip := net.ParseIP(addr); ip == nil {
|
||||
panic("invalid ip indexServer.address")
|
||||
panic("invalid ip indexService.address")
|
||||
}
|
||||
}
|
||||
|
||||
port, err := pt.Load("indexServer.port")
|
||||
port, err := pt.Load("indexService.port")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
|
@ -56,10 +56,6 @@ func (pt *ParamTable) LoadFromEnv() {
|
|||
pt.QueryNodeID = UniqueID(queryID)
|
||||
|
||||
Params.QueryNodeIP = funcutil.GetLocalIP()
|
||||
host := os.Getenv("QUERY_NODE_HOST")
|
||||
if len(host) > 0 {
|
||||
Params.QueryNodeIP = host
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ func (pt *ParamTable) Init() {
|
|||
}
|
||||
|
||||
func (pt *ParamTable) initAddress() {
|
||||
addr, err := pt.Load("indexServer.address")
|
||||
addr, err := pt.Load("indexService.address")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ func (pt *ParamTable) initAddress() {
|
|||
}
|
||||
}
|
||||
|
||||
port, err := pt.Load("indexServer.port")
|
||||
port, err := pt.Load("indexService.port")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
@ -73,7 +73,7 @@ func (pt *ParamTable) initAddress() {
|
|||
}
|
||||
|
||||
func (pt *ParamTable) initPort() {
|
||||
pt.Port = pt.ParseInt("indexServer.port")
|
||||
pt.Port = pt.ParseInt("indexService.port")
|
||||
}
|
||||
|
||||
func (pt *ParamTable) initEtcdAddress() {
|
||||
|
|
|
@ -164,11 +164,11 @@ func (gp *BaseTable) tryloadFromEnv() {
|
|||
|
||||
indexBuilderAddress := os.Getenv("INDEX_SERVICE_ADDRESS")
|
||||
if indexBuilderAddress == "" {
|
||||
indexBuilderHost, err := gp.Load("indexServer.address")
|
||||
indexBuilderHost, err := gp.Load("indexService.address")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
port, err := gp.Load("indexServer.port")
|
||||
port, err := gp.Load("indexService.port")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue