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

feat(cstor-operator): filter out released block devices during auto provisioning #1310

Merged
merged 1 commit into from
Jun 19, 2019

Conversation

mittachaitu
Copy link

Signed-off-by: mittachaitu [email protected]

What this PR does / why we need it:
This PR adds the filter to filter out block devices which are in released state during auto provision mode.

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #

Special notes for your reviewer:

Checklist:

  • Fixes #
  • Labelled this PR & related issue with documentation tag
  • PR messages has document related information
  • Labelled this PR & related issue with breaking-changes tag
  • PR messages has breaking changes related information
  • Labelled this PR & related issue with requires-upgrade tag
  • PR messages has upgrade related information
  • Commit has unit tests
  • Commit has integration tests

…es during auto provisioning

Signed-off-by: mittachaitu <[email protected]>
Copy link
Contributor

@prateekpandey14 prateekpandey14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mittachaitu mittachaitu changed the title feat(cstor-operator): add a filter to filter out released block devices during auto provisioning feat(cstor-operator): filter out released block devices during auto provisioning Jun 19, 2019
@@ -289,6 +291,19 @@ func filterNonSparseDevices(originalList *BlockDeviceList) *BlockDeviceList {
return filteredList
}

func filterNonRelesedDevices(originalList *BlockDeviceList) *BlockDeviceList {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let us write a comment for this function. Is this supposed to return a list of BDs whose claimstate is "Released" ?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It will return BDs whose claimstate is other than Released. Will add a comment in next PR

Copy link
Contributor

@vishnuitta vishnuitta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changes are good

@vishnuitta vishnuitta merged commit 311727e into openebs-archive:master Jun 19, 2019
FilterSparseDevices = "filterSparseDevices"
FilterNonSparseDevices = "filterNonSparseDevices"
InActiveStatus = "Inactive"
FilterNonRelesedDevices = "filterNonRelesedDevices"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spell check

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Corrected in cherry-pick PR will do it in next PR

mittachaitu pushed a commit to mittachaitu/maya that referenced this pull request Jun 19, 2019
vishnuitta pushed a commit that referenced this pull request Jun 19, 2019
… during auto provisioning (#1312)

* fix(cstor-operator): honour spc type in case of manual provisioning of cStor pool (#1281)

Signed-off-by: mittachaitu <[email protected]>

* feat(cstor-operator): filter out released block devices during auto provisioning (#1310)

Signed-off-by: mittachaitu <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants