Skip to content

orch: refactor boolean handling in drive group spec#59752

Merged
adk3798 merged 1 commit intoceph:mainfrom
guits:drive-group-spec-bool-args
Sep 16, 2024
Merged

orch: refactor boolean handling in drive group spec#59752
adk3798 merged 1 commit intoceph:mainfrom
guits:drive-group-spec-bool-args

Conversation

@guits
Copy link
Copy Markdown
Contributor

@guits guits commented Sep 12, 2024

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

@guits guits requested a review from a team as a code owner September 12, 2024 06:24
@guits guits force-pushed the drive-group-spec-bool-args branch 2 times, most recently from 2b046c9 to 4a483a0 Compare September 12, 2024 09:23
@guits guits force-pushed the drive-group-spec-bool-args branch from 4a483a0 to 5cd999d Compare September 12, 2024 12:31
@guits
Copy link
Copy Markdown
Contributor Author

guits commented Sep 13, 2024

jenkins test make check

@guits guits force-pushed the drive-group-spec-bool-args branch from 5cd999d to b8bc17e Compare September 13, 2024 05:32
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>
@guits guits force-pushed the drive-group-spec-bool-args branch from b8bc17e to e3d8a37 Compare September 13, 2024 12:40
@guits guits requested a review from adk3798 September 13, 2024 12:40
@guits
Copy link
Copy Markdown
Contributor Author

guits commented Sep 16, 2024

jenkins test api

2 similar comments
@guits
Copy link
Copy Markdown
Contributor Author

guits commented Sep 16, 2024

jenkins test api

@guits
Copy link
Copy Markdown
Contributor Author

guits commented Sep 16, 2024

jenkins test api

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants