Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
demoManito committed Apr 22, 2024
1 parent c657d4a commit 18d5f54
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions contrib/polaris/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ func buildPolarisInstance(namespace string, nodes []selector.Node) *pb.ServiceIn
if err != nil {
return nil
}
portInt, err := strconv.ParseUint(port, 10, 32) //nolint:gomnd
portUint64, err := strconv.ParseUint(port, 10, 32) //nolint:gomnd
if err != nil {
return nil
}
Expand All @@ -123,7 +123,7 @@ func buildPolarisInstance(namespace string, nodes []selector.Node) *pb.ServiceIn
Service: wrapperspb.String(node.ServiceName()),
Namespace: wrapperspb.String(namespace),
Host: wrapperspb.String(host),
Port: wrapperspb.UInt32(uint32(portInt)),
Port: wrapperspb.UInt32(uint32(portUint64)),
Protocol: wrapperspb.String(node.Scheme()),
Version: wrapperspb.String(node.Version()),
Weight: wrapperspb.UInt32(uint32(*node.InitialWeight())),
Expand Down

0 comments on commit 18d5f54

Please sign in to comment.