orch: refactor boolean handling in drive group spec#59752
Merged
Conversation
2b046c9 to
4a483a0
Compare
adk3798
reviewed
Sep 12, 2024
4a483a0 to
5cd999d
Compare
adk3798
approved these changes
Sep 12, 2024
Contributor
Author
|
jenkins test make check |
5cd999d to
b8bc17e
Compare
The intent of 42721c0 was to address an issue where boolean parameters weren't handled correctly. I noticed that a parameter (`tpm2`) was missed, which made me realize that maintaining a list of these boolean parameters is necessary. To simplify things, we should only accept `"true"` or `"false"` (in any case), allowing us to avoid the need to maintain a list of boolean parameters. This change introduces a `list_drive_group_spec_bool_arg` to store boolean arguments related to drive group specifications, simplifying the validation process for boolean values by directly checking if the values are 'true' or 'false'. Fixes: https://tracker.ceph.com/issues/68045 Signed-off-by: Guillaume Abrioux <gabrioux@ibm.com>
b8bc17e to
e3d8a37
Compare
adk3798
approved these changes
Sep 13, 2024
Contributor
Author
|
jenkins test api |
2 similar comments
Contributor
Author
|
jenkins test api |
Contributor
Author
|
jenkins test api |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The intent of 42721c0 was to address an issue where boolean parameters weren't handled correctly.
I noticed that a parameter (
tpm2) was missed, which made me realize that maintaining a list of these boolean parameters is necessary.To simplify things, we should only accept
"true"or"false"(in any case), allowing us to avoid the need to maintain a list of boolean parameters.This change introduces a
list_drive_group_spec_bool_argto store boolean arguments related to drive group specifications, simplifying the validation process for boolean values by directly checking if the values are 'true' or 'false'.Fixes: https://tracker.ceph.com/issues/68045