Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
milvus
milvus
提交
e281f6a4
M
milvus
项目概览
milvus
/
milvus
11 个月 前同步成功
通知
261
Star
22476
Fork
2472
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
milvus
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
e281f6a4
编写于
4月 13, 2021
作者:
X
XuanYang-cn
提交者:
yefu.chen
4月 13, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Remove useless configs in config files
Signed-off-by:
N
XuanYang-cn
<
xuan.yang@zilliz.com
>
上级
a7dac818
变更
15
隐藏空白更改
内联
并排
Showing
15 changed file
with
24 addition
and
119 deletion
+24
-119
configs/advanced/channel.yaml
configs/advanced/channel.yaml
+0
-3
configs/advanced/common.yaml
configs/advanced/common.yaml
+0
-1
configs/advanced/data_node.yaml
configs/advanced/data_node.yaml
+1
-3
configs/advanced/data_service.yaml
configs/advanced/data_service.yaml
+1
-3
configs/advanced/master.yaml
configs/advanced/master.yaml
+0
-12
configs/advanced/proxy_node.yaml
configs/advanced/proxy_node.yaml
+0
-1
configs/advanced/query_node.yaml
configs/advanced/query_node.yaml
+0
-2
configs/milvus.yaml
configs/milvus.yaml
+8
-16
docs/developer_guides/chap05_proxy.md
docs/developer_guides/chap05_proxy.md
+1
-1
internal/proxynode/impl.go
internal/proxynode/impl.go
+1
-1
internal/proxynode/paramtable.go
internal/proxynode/paramtable.go
+5
-23
internal/proxynode/task.go
internal/proxynode/task.go
+1
-1
internal/querynode/load_service_test.go
internal/querynode/load_service_test.go
+0
-1
internal/querynode/param_table.go
internal/querynode/param_table.go
+3
-13
internal/util/paramtable/paramtable.go
internal/util/paramtable/paramtable.go
+3
-38
未找到文件。
configs/advanced/channel.yaml
浏览文件 @
e281f6a4
...
@@ -22,11 +22,9 @@ msgChannel:
...
@@ -22,11 +22,9 @@ msgChannel:
k2s
:
"
k2s"
k2s
:
"
k2s"
proxyTimeTick
:
"
proxyTimeTick"
proxyTimeTick
:
"
proxyTimeTick"
proxyServiceTimeTick
:
"
proxyServiceTimeTick"
proxyServiceTimeTick
:
"
proxyServiceTimeTick"
writeNodeTimeTick
:
"
writeNodeTimeTick"
# GOOSE TODO: remove this
dataNodeTimeTick
:
"
dataNodeTimeTick"
dataNodeTimeTick
:
"
dataNodeTimeTick"
queryTimeTick
:
"
queryTimeTick"
queryTimeTick
:
"
queryTimeTick"
dataNodeSegStatistics
:
"
dataNodeSegStatistics"
dataNodeSegStatistics
:
"
dataNodeSegStatistics"
# old name: statsChannels: "statistic"
queryNodeStats
:
"
query-node-stats"
queryNodeStats
:
"
query-node-stats"
# cmd for loadIndex, flush, etc...
# cmd for loadIndex, flush, etc...
cmd
:
"
cmd"
cmd
:
"
cmd"
...
@@ -40,7 +38,6 @@ msgChannel:
...
@@ -40,7 +38,6 @@ msgChannel:
masterSubNamePrefix
:
"
master"
masterSubNamePrefix
:
"
master"
proxySubNamePrefix
:
"
proxy"
proxySubNamePrefix
:
"
proxy"
queryNodeSubNamePrefix
:
"
queryNode"
queryNodeSubNamePrefix
:
"
queryNode"
writeNodeSubNamePrefix
:
"
writeNode"
# GOOSE TODO: remove this
dataNodeSubNamePrefix
:
"
dataNode"
dataNodeSubNamePrefix
:
"
dataNode"
dataServiceSubNamePrefix
:
"
dataService"
dataServiceSubNamePrefix
:
"
dataService"
...
...
configs/advanced/common.yaml
浏览文件 @
e281f6a4
...
@@ -10,6 +10,5 @@
...
@@ -10,6 +10,5 @@
# or implied. See the License for the specific language governing permissions and limitations under the License.
# or implied. See the License for the specific language governing permissions and limitations under the License.
common
:
common
:
defaultPartitionTag
:
_default
#TODO, remove
defaultPartitionName
:
"
_default"
defaultPartitionName
:
"
_default"
defaultIndexName
:
"
_default_idx"
defaultIndexName
:
"
_default_idx"
configs/advanced/data_node.yaml
浏览文件 @
e281f6a4
...
@@ -23,12 +23,10 @@ dataNode:
...
@@ -23,12 +23,10 @@ dataNode:
pulsarBufSize
:
64
# pulsar chan buffer size
pulsarBufSize
:
64
# pulsar chan buffer size
insert
:
insert
:
#streamBufSize: 1024 # msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
delete
:
delete
:
#streamBufSize: 1024 # msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
...
@@ -38,5 +36,5 @@ dataNode:
...
@@ -38,5 +36,5 @@ dataNode:
flush
:
flush
:
# max buffer size to flush
# max buffer size to flush
insertBufSize
:
32000
insertBufSize
:
32000
# number of rows
ddBufSize
:
20
ddBufSize
:
20
configs/advanced/data_service.yaml
浏览文件 @
e281f6a4
...
@@ -3,11 +3,9 @@ dataservice:
...
@@ -3,11 +3,9 @@ dataservice:
address
:
"
127.0.0.1"
address
:
"
127.0.0.1"
port
:
13333
port
:
13333
segment
:
segment
:
# old name: segmentThreshold: 536870912
size
:
512
# MB
size
:
512
# MB
sizeFactor
:
0.75
sizeFactor
:
0.75
defaultSizePerRecord
:
1024
defaultSizePerRecord
:
1024
# old name: segmentExpireDuration: 2000
IDAssignExpiration
:
2000
# ms
IDAssignExpiration
:
2000
# ms
insertChannelNum
:
2
insertChannelNum
:
2
dataNodeNum
:
1
dataNodeNum
:
1
\ No newline at end of file
configs/advanced/master.yaml
浏览文件 @
e281f6a4
...
@@ -10,18 +10,6 @@
...
@@ -10,18 +10,6 @@
# or implied. See the License for the specific language governing permissions and limitations under the License.
# or implied. See the License for the specific language governing permissions and limitations under the License.
master
:
master
:
timeSync
:
softTimeTickBarrierInterval
:
500
# ms
segment
:
# old name: segmentThreshold: 536870912
size
:
512
# MB
sizeFactor
:
0.75
defaultSizePerRecord
:
1024
minIDAssignCnt
:
1024
maxIDAssignCnt
:
16384
# old name: segmentExpireDuration: 2000
IDAssignExpiration
:
2000
# ms
maxPartitionNum
:
4096
maxPartitionNum
:
4096
minSegmentSizeToEnableIndex
:
1024
minSegmentSizeToEnableIndex
:
1024
nodeID
:
100
nodeID
:
100
...
...
configs/advanced/proxy_node.yaml
浏览文件 @
e281f6a4
...
@@ -14,7 +14,6 @@ proxyNode:
...
@@ -14,7 +14,6 @@ proxyNode:
msgStream
:
msgStream
:
insert
:
insert
:
#streamBufSize: 1024 # msgPack chan buffer size
bufSize
:
1024
# msgPack chan buffer size
bufSize
:
1024
# msgPack chan buffer size
search
:
search
:
...
...
configs/advanced/query_node.yaml
浏览文件 @
e281f6a4
...
@@ -20,7 +20,6 @@ queryNode:
...
@@ -20,7 +20,6 @@ queryNode:
msgStream
:
msgStream
:
insert
:
insert
:
#streamBufSize: 1024 # msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
...
@@ -29,7 +28,6 @@ queryNode:
...
@@ -29,7 +28,6 @@ queryNode:
pulsarBufSize
:
64
# pulsar chan buffer size
pulsarBufSize
:
64
# pulsar chan buffer size
delete
:
delete
:
#streamBufSize: 1024 # msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
recvBufSize
:
1024
# msgPack chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
pulsarBufSize
:
1024
# pulsar chan buffer size
...
...
configs/milvus.yaml
浏览文件 @
e281f6a4
...
@@ -10,10 +10,9 @@
...
@@ -10,10 +10,9 @@
# or implied. See the License for the specific language governing permissions and limitations under the License.
# or implied. See the License for the specific language governing permissions and limitations under the License.
nodeID
:
# will be deprecated after v0.2
nodeID
:
# will be deprecated later
proxyIDList
:
[
0
]
queryNodeIDList
:
[
1
]
queryNodeIDList
:
[
1
]
dataNodeIDList
:
[
3
]
dataNodeIDList
:
[
3
]
etcd
:
etcd
:
address
:
localhost
address
:
localhost
...
@@ -22,10 +21,7 @@ etcd:
...
@@ -22,10 +21,7 @@ etcd:
metaSubPath
:
meta
# metaRootPath = rootPath + '/' + metaSubPath
metaSubPath
:
meta
# metaRootPath = rootPath + '/' + metaSubPath
kvSubPath
:
kv
# kvRootPath = rootPath + '/' + kvSubPath
kvSubPath
:
kv
# kvRootPath = rootPath + '/' + kvSubPath
segFlushMetaSubPath
:
datanode/segment
# Full Path = rootPath/metaSubPath/segFlushMetaSubPath
segFlushMetaSubPath
:
datanode/segment
# Full Path = rootPath/metaSubPath/segFlushMetaSubPath
ddlFlushMetaSubPath
:
datanode/ddl
# Full Path = rootPath/metaSubPaht/ddlFlushMetaSubPath
ddlFlushMetaSubPath
:
datanode/ddl
# Full Path = rootPath/metaSubPath/ddlFlushMetaSubPath
writeNodeSegKvSubPath
:
writer/segment
# GOOSE TODO: remove this
writeNodeDDLKvSubPath
:
writer/ddl
# GOOSE TODO: remove this
segThreshold
:
10000
minio
:
minio
:
address
:
localhost
address
:
localhost
...
@@ -38,11 +34,7 @@ minio:
...
@@ -38,11 +34,7 @@ minio:
pulsar
:
pulsar
:
address
:
localhost
address
:
localhost
port
:
6650
port
:
6650
rest-port
:
18080
# keep same with pulsar container
maxMessageSize
:
5242880
# 5 * 1024 * 1024 Bytes
maxMessageSize
:
5242880
# 5 * 1024 * 1024
authentication
:
false
user
:
user-default
token
:
eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJKb2UifQ.ipevRNuRP6HflG8cFKnmUPtypruRC4fb1DWtoLL62SY
master
:
master
:
address
:
localhost
address
:
localhost
...
@@ -60,7 +52,7 @@ proxyService:
...
@@ -60,7 +52,7 @@ proxyService:
port
:
21122
port
:
21122
queryNode
:
queryNode
:
gracefulTime
:
5000
#
ms
gracefulTime
:
5000
#
ms, for search
port
:
21123
port
:
21123
indexService
:
indexService
:
...
@@ -78,11 +70,11 @@ dataNode:
...
@@ -78,11 +70,11 @@ dataNode:
port
:
21124
port
:
21124
log
:
log
:
level
:
debug
level
:
debug
# info, warn, error, panic, fatal, dpanic,
file
:
file
:
rootPath
:
"
"
rootPath
:
"
"
# default to stdout, stderr
maxSize
:
300
# MB
maxSize
:
300
# MB
maxAge
:
10
# day
maxAge
:
10
# day
maxBackups
:
20
maxBackups
:
20
dev
:
true
dev
:
true
# false, change behaviour of dpaniclevel
format
:
text
# text/json
format
:
text
# text/json
docs/developer_guides/chap05_proxy.md
浏览文件 @
e281f6a4
...
@@ -403,7 +403,7 @@ type GlobalParamsTable struct {
...
@@ -403,7 +403,7 @@ type GlobalParamsTable struct {
MaxNameLength
int64
MaxNameLength
int64
MaxFieldNum
int64
MaxFieldNum
int64
MaxDimension
int64
MaxDimension
int64
DefaultPartition
Tag
string
DefaultPartition
Name
string
DefaultIndexName
string
DefaultIndexName
string
}
}
...
...
internal/proxynode/impl.go
浏览文件 @
e281f6a4
...
@@ -946,7 +946,7 @@ func (node *ProxyNode) Insert(ctx context.Context, request *milvuspb.InsertReque
...
@@ -946,7 +946,7 @@ func (node *ProxyNode) Insert(ctx context.Context, request *milvuspb.InsertReque
rowIDAllocator
:
node
.
idAllocator
,
rowIDAllocator
:
node
.
idAllocator
,
}
}
if
len
(
it
.
PartitionName
)
<=
0
{
if
len
(
it
.
PartitionName
)
<=
0
{
it
.
PartitionName
=
Params
.
DefaultPartition
Tag
it
.
PartitionName
=
Params
.
DefaultPartition
Name
}
}
err
:=
node
.
sched
.
DmQueue
.
Enqueue
(
it
)
err
:=
node
.
sched
.
DmQueue
.
Enqueue
(
it
)
...
...
internal/proxynode/paramtable.go
浏览文件 @
e281f6a4
...
@@ -54,7 +54,7 @@ type ParamTable struct {
...
@@ -54,7 +54,7 @@ type ParamTable struct {
MaxNameLength
int64
MaxNameLength
int64
MaxFieldNum
int64
MaxFieldNum
int64
MaxDimension
int64
MaxDimension
int64
DefaultPartition
Tag
string
DefaultPartition
Name
string
DefaultIndexName
string
DefaultIndexName
string
PulsarMaxMessageSize
int
PulsarMaxMessageSize
int
...
@@ -136,7 +136,6 @@ func (pt *ParamTable) initParams() {
...
@@ -136,7 +136,6 @@ func (pt *ParamTable) initParams() {
pt
.
initPulsarAddress
()
pt
.
initPulsarAddress
()
pt
.
initQueryNodeIDList
()
pt
.
initQueryNodeIDList
()
pt
.
initQueryNodeNum
()
pt
.
initQueryNodeNum
()
// pt.initProxyID()
pt
.
initTimeTickInterval
()
pt
.
initTimeTickInterval
()
pt
.
initInsertChannelNames
()
pt
.
initInsertChannelNames
()
pt
.
initDeleteChannelNames
()
pt
.
initDeleteChannelNames
()
...
@@ -154,7 +153,7 @@ func (pt *ParamTable) initParams() {
...
@@ -154,7 +153,7 @@ func (pt *ParamTable) initParams() {
pt
.
initMaxNameLength
()
pt
.
initMaxNameLength
()
pt
.
initMaxFieldNum
()
pt
.
initMaxFieldNum
()
pt
.
initMaxDimension
()
pt
.
initMaxDimension
()
pt
.
initDefaultPartition
Tag
()
pt
.
initDefaultPartition
Name
()
pt
.
initDefaultIndexName
()
pt
.
initDefaultIndexName
()
pt
.
initPulsarMaxMessageSize
()
pt
.
initPulsarMaxMessageSize
()
...
@@ -191,18 +190,6 @@ func (pt *ParamTable) initQueryNodeIDList() []UniqueID {
...
@@ -191,18 +190,6 @@ func (pt *ParamTable) initQueryNodeIDList() []UniqueID {
return
ret
return
ret
}
}
func
(
pt
*
ParamTable
)
initProxyID
()
{
proxyID
,
err
:=
pt
.
Load
(
"_proxyID"
)
if
err
!=
nil
{
panic
(
err
)
}
ID
,
err
:=
strconv
.
Atoi
(
proxyID
)
if
err
!=
nil
{
panic
(
err
)
}
pt
.
ProxyID
=
UniqueID
(
ID
)
}
func
(
pt
*
ParamTable
)
initTimeTickInterval
()
{
func
(
pt
*
ParamTable
)
initTimeTickInterval
()
{
intervalStr
,
err
:=
pt
.
Load
(
"proxyNode.timeTickInterval"
)
intervalStr
,
err
:=
pt
.
Load
(
"proxyNode.timeTickInterval"
)
if
err
!=
nil
{
if
err
!=
nil
{
...
@@ -311,11 +298,6 @@ func (pt *ParamTable) initProxySubName() {
...
@@ -311,11 +298,6 @@ func (pt *ParamTable) initProxySubName() {
if
err
!=
nil
{
if
err
!=
nil
{
panic
(
err
)
panic
(
err
)
}
}
pt
.
ProxySubName
=
prefix
// proxyIDStr, err := pt.Load("_proxyID")
// if err != nil {
// panic(err)
// }
pt
.
ProxySubName
=
prefix
+
"-"
+
strconv
.
Itoa
(
int
(
pt
.
ProxyID
))
pt
.
ProxySubName
=
prefix
+
"-"
+
strconv
.
Itoa
(
int
(
pt
.
ProxyID
))
}
}
...
@@ -393,12 +375,12 @@ func (pt *ParamTable) initMaxDimension() {
...
@@ -393,12 +375,12 @@ func (pt *ParamTable) initMaxDimension() {
pt
.
MaxDimension
=
maxDimension
pt
.
MaxDimension
=
maxDimension
}
}
func
(
pt
*
ParamTable
)
initDefaultPartition
Tag
()
{
func
(
pt
*
ParamTable
)
initDefaultPartition
Name
()
{
tag
,
err
:=
pt
.
Load
(
"common.defaultPartitionTag
"
)
name
,
err
:=
pt
.
Load
(
"common.defaultPartitionName
"
)
if
err
!=
nil
{
if
err
!=
nil
{
panic
(
err
)
panic
(
err
)
}
}
pt
.
DefaultPartition
Tag
=
tag
pt
.
DefaultPartition
Name
=
name
}
}
func
(
pt
*
ParamTable
)
initDefaultIndexName
()
{
func
(
pt
*
ParamTable
)
initDefaultIndexName
()
{
...
...
internal/proxynode/task.go
浏览文件 @
e281f6a4
...
@@ -159,7 +159,7 @@ func (it *InsertTask) Execute(ctx context.Context) error {
...
@@ -159,7 +159,7 @@ func (it *InsertTask) Execute(ctx context.Context) error {
return
err
return
err
}
}
}
else
{
}
else
{
partitionID
,
err
=
globalMetaCache
.
GetPartitionID
(
ctx
,
collectionName
,
Params
.
DefaultPartition
Tag
)
partitionID
,
err
=
globalMetaCache
.
GetPartitionID
(
ctx
,
collectionName
,
Params
.
DefaultPartition
Name
)
if
err
!=
nil
{
if
err
!=
nil
{
return
err
return
err
}
}
...
...
internal/querynode/load_service_test.go
浏览文件 @
e281f6a4
...
@@ -1122,7 +1122,6 @@ func TestSegmentLoad_Search_Vector(t *testing.T) {
...
@@ -1122,7 +1122,6 @@ func TestSegmentLoad_Search_Vector(t *testing.T) {
// mock write insert bin log
// mock write insert bin log
keyPrefix
:=
path
.
Join
(
"query-node-seg-manager-test-minio-prefix"
,
strconv
.
FormatInt
(
collectionID
,
10
),
strconv
.
FormatInt
(
partitionID
,
10
))
keyPrefix
:=
path
.
Join
(
"query-node-seg-manager-test-minio-prefix"
,
strconv
.
FormatInt
(
collectionID
,
10
),
strconv
.
FormatInt
(
partitionID
,
10
))
Params
.
WriteNodeSegKvSubPath
=
keyPrefix
node
:=
newQueryNodeMock
()
node
:=
newQueryNodeMock
()
defer
node
.
Stop
()
defer
node
.
Stop
()
...
...
internal/querynode/param_table.go
浏览文件 @
e281f6a4
...
@@ -14,10 +14,9 @@ import (
...
@@ -14,10 +14,9 @@ import (
type
ParamTable
struct
{
type
ParamTable
struct
{
paramtable
.
BaseTable
paramtable
.
BaseTable
PulsarAddress
string
PulsarAddress
string
ETCDAddress
string
ETCDAddress
string
MetaRootPath
string
MetaRootPath
string
WriteNodeSegKvSubPath
string
QueryNodeIP
string
QueryNodeIP
string
QueryNodePort
int64
QueryNodePort
int64
...
@@ -106,7 +105,6 @@ func (p *ParamTable) Init() {
...
@@ -106,7 +105,6 @@ func (p *ParamTable) Init() {
p
.
initPulsarAddress
()
p
.
initPulsarAddress
()
p
.
initETCDAddress
()
p
.
initETCDAddress
()
p
.
initMetaRootPath
()
p
.
initMetaRootPath
()
p
.
initWriteNodeSegKvSubPath
()
p
.
initGracefulTime
()
p
.
initGracefulTime
()
p
.
initMsgChannelSubName
()
p
.
initMsgChannelSubName
()
...
@@ -312,14 +310,6 @@ func (p *ParamTable) initMetaRootPath() {
...
@@ -312,14 +310,6 @@ func (p *ParamTable) initMetaRootPath() {
p
.
MetaRootPath
=
rootPath
+
"/"
+
subPath
p
.
MetaRootPath
=
rootPath
+
"/"
+
subPath
}
}
func
(
p
*
ParamTable
)
initWriteNodeSegKvSubPath
()
{
subPath
,
err
:=
p
.
Load
(
"etcd.writeNodeSegKvSubPath"
)
if
err
!=
nil
{
panic
(
err
)
}
p
.
WriteNodeSegKvSubPath
=
subPath
+
"/"
}
func
(
p
*
ParamTable
)
initGracefulTime
()
{
func
(
p
*
ParamTable
)
initGracefulTime
()
{
p
.
GracefulTime
=
p
.
ParseInt64
(
"queryNode.gracefulTime"
)
p
.
GracefulTime
=
p
.
ParseInt64
(
"queryNode.gracefulTime"
)
}
}
...
...
internal/util/paramtable/paramtable.go
浏览文件 @
e281f6a4
...
@@ -329,32 +329,14 @@ func (gp *BaseTable) ParseInt(key string) int {
...
@@ -329,32 +329,14 @@ func (gp *BaseTable) ParseInt(key string) int {
return
value
return
value
}
}
// GOOSE TODO: remove writenode
func
(
gp
*
BaseTable
)
WriteNodeIDList
()
[]
UniqueID
{
proxyIDStr
,
err
:=
gp
.
Load
(
"nodeID.dataNodeIDList"
)
if
err
!=
nil
{
panic
(
err
)
}
var
ret
[]
UniqueID
proxyIDs
:=
strings
.
Split
(
proxyIDStr
,
","
)
for
_
,
i
:=
range
proxyIDs
{
v
,
err
:=
strconv
.
Atoi
(
i
)
if
err
!=
nil
{
log
.
Panicf
(
"load write node id list error, %s"
,
err
.
Error
())
}
ret
=
append
(
ret
,
UniqueID
(
v
))
}
return
ret
}
func
(
gp
*
BaseTable
)
DataNodeIDList
()
[]
UniqueID
{
func
(
gp
*
BaseTable
)
DataNodeIDList
()
[]
UniqueID
{
proxy
IDStr
,
err
:=
gp
.
Load
(
"nodeID.dataNodeIDList"
)
datanode
IDStr
,
err
:=
gp
.
Load
(
"nodeID.dataNodeIDList"
)
if
err
!=
nil
{
if
err
!=
nil
{
panic
(
err
)
panic
(
err
)
}
}
var
ret
[]
UniqueID
var
ret
[]
UniqueID
proxyIDs
:=
strings
.
Split
(
proxy
IDStr
,
","
)
datanodeIDs
:=
strings
.
Split
(
datanode
IDStr
,
","
)
for
_
,
i
:=
range
proxy
IDs
{
for
_
,
i
:=
range
datanode
IDs
{
v
,
err
:=
strconv
.
Atoi
(
i
)
v
,
err
:=
strconv
.
Atoi
(
i
)
if
err
!=
nil
{
if
err
!=
nil
{
log
.
Panicf
(
"load write node id list error, %s"
,
err
.
Error
())
log
.
Panicf
(
"load write node id list error, %s"
,
err
.
Error
())
...
@@ -364,23 +346,6 @@ func (gp *BaseTable) DataNodeIDList() []UniqueID {
...
@@ -364,23 +346,6 @@ func (gp *BaseTable) DataNodeIDList() []UniqueID {
return
ret
return
ret
}
}
func
(
gp
*
BaseTable
)
ProxyIDList
()
[]
UniqueID
{
proxyIDStr
,
err
:=
gp
.
Load
(
"nodeID.proxyIDList"
)
if
err
!=
nil
{
panic
(
err
)
}
var
ret
[]
UniqueID
proxyIDs
:=
strings
.
Split
(
proxyIDStr
,
","
)
for
_
,
i
:=
range
proxyIDs
{
v
,
err
:=
strconv
.
Atoi
(
i
)
if
err
!=
nil
{
log
.
Panicf
(
"load proxy id list error, %s"
,
err
.
Error
())
}
ret
=
append
(
ret
,
UniqueID
(
v
))
}
return
ret
}
func
(
gp
*
BaseTable
)
QueryNodeIDList
()
[]
UniqueID
{
func
(
gp
*
BaseTable
)
QueryNodeIDList
()
[]
UniqueID
{
queryNodeIDStr
,
err
:=
gp
.
Load
(
"nodeID.queryNodeIDList"
)
queryNodeIDStr
,
err
:=
gp
.
Load
(
"nodeID.queryNodeIDList"
)
if
err
!=
nil
{
if
err
!=
nil
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录