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

rpk: display float values as float in cluster config get #18841

Merged
merged 1 commit into from
Jun 6, 2024

Conversation

r-vasquez
Copy link
Contributor

In 610e3ad we introduced a fix for #6070, to avoid printing large numbers with scientific notation, we treated all numbers as integers.

Now, the API uses float values and they are rounded by rpk, this change introduces a mod check to determine whether the number is an integer or a float.

# Before
$ rpk cluster config get kafka_memory_share_for_fetch
0

# Now
$ rpk cluster config get kafka_memory_share_for_fetch
0.5

Backports Required

  • none - not a bug fix
  • none - this is a backport
  • none - issue does not exist in previous branches
  • none - papercut/not impactful enough to backport
  • v24.1.x
  • v23.3.x
  • v23.2.x

Release Notes

Bug Fixes

  • rpk cluster config get: does not round float numbers anymore.

In 610e3ad we introduced a fix for redpanda-data#6070, to avoid
printing large numbers with scientific notation, we
treated all numbers as integers.

Now, the API uses float values and they are being
rounded, this change introduce a mod check to
determine whether the number is an integer or a
float.
@r-vasquez r-vasquez merged commit ca0d7d1 into redpanda-data:dev Jun 6, 2024
24 checks passed
@vbotbuildovich
Copy link
Collaborator

/backport v24.1.x

@vbotbuildovich
Copy link
Collaborator

/backport v23.3.x

@vbotbuildovich
Copy link
Collaborator

/backport v23.2.x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants