Worker maintenance tasks now use non-default grpcPort if configured (#8407)

Fixes #8401

When creating balance/vacuum tasks, the worker maintenance scheduler was
accidentally discarding the custom grpcPort defined on the DataNodeInfo
by using just its HTTP Address string, which defaults to +10000
during grpc dialing.

By using pb.NewServerAddressFromDataNode, the grpcPort suffix is correctly
encoded in the server address string, preventing connection refused errors
for users running volume servers with custom gRPC ports.
This commit is contained in:
Chris Lu
2026-02-22 22:40:14 -08:00
committed by GitHub
parent cd6832249b
commit 998c8d2702
2 changed files with 5 additions and 5 deletions

View File

@@ -575,7 +575,7 @@ func buildVolumeMetrics(
metric := &workertypes.VolumeHealthMetrics{
VolumeID: volume.Id,
Server: node.Id,
ServerAddress: node.Address,
ServerAddress: string(pb.NewServerAddressFromDataNode(node)),
DiskType: diskType,
DiskId: volume.DiskId,
DataCenter: dc.Id,