Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rework integer type selection #3144

Merged
merged 2 commits into from
Sep 17, 2024
Merged

Conversation

skitt
Copy link
Member

@skitt skitt commented Aug 30, 2024

Following the recent gosec-related int work (to annotate known-safe conversions), this furthers that by:

  • using ints instead of uints for healthcheck configuration and tracking
  • using uint32 instead of int for IP pool sizes, since their use is tied to uint32 representations of IP addresses
  • using fmt.Sprintf instead of manual string concatenation to construct the connectivity verification command

@submariner-bot
Copy link
Contributor

🤖 Created branch: z_pr3144/skitt/int-cleanup
🚀 Full E2E won't run until the "ready-to-test" label is applied. I will add it automatically once the PR has 2 approvals, or you can add it manually.

pkg/ipam/ippool.go Outdated Show resolved Hide resolved
@skitt skitt force-pushed the int-cleanup branch 2 times, most recently from 0c08ac8 to c39c3d4 Compare August 30, 2024 12:30
@skitt skitt mentioned this pull request Aug 30, 2024
@skitt skitt marked this pull request as ready for review September 11, 2024 13:53
@tpantelis tpantelis force-pushed the int-cleanup branch 2 times, most recently from af5a9a7 to a6e6f31 Compare September 16, 2024 19:54
Following the recent gosec-related int work (to annotate known-safe
conversions), this furthers that by:

* using ints instead of uints for healthcheck configuration and
  tracking
* using uint32 instead of int for IP pool sizes, since their use is
  tied to uint32 representations of IP addresses
* using fmt.Sprintf instead of manual string concatenation to
  construct the connectivity verification command
* using int32 for nat discovery IPPortPair

Signed-off-by: Stephen Kitt <skitt@redhat.com>
@tpantelis
Copy link
Contributor

The linting failures need the shipyard golangci-lint bump.

@tpantelis tpantelis added the ready-to-test When a PR is ready for full E2E testing label Sep 17, 2024
@tpantelis tpantelis merged commit fce5424 into submariner-io:devel Sep 17, 2024
41 checks passed
@submariner-bot
Copy link
Contributor

🤖 Closed branches: [z_pr3144/skitt/int-cleanup]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-test When a PR is ready for full E2E testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants