Skip to content

Commit 8931304

Browse files
committed
[fix][instance] calculate instance_start_id with instance num and sequence
1 parent aea5a1a commit 8931304

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

internal/configure/topology/dc_item.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -475,7 +475,10 @@ var (
475475
REQUIRE_POSITIVE_INTEGER,
476476
true,
477477
func(dc *DeployConfig) interface{} {
478-
return DEFAULT_STORE_INSTANCE_START_ID + dc.GetHostSequence()
478+
if dc.GetInstances() > 0 {
479+
return DEFAULT_STORE_INSTANCE_START_ID + dc.GetHostSequence()*dc.GetInstances() + dc.GetInstancesSequence()
480+
}
481+
return DEFAULT_STORE_INSTANCE_START_ID + dc.GetHostSequence() + dc.GetInstancesSequence()
479482
},
480483
)
481484

0 commit comments

Comments
 (0)